Home/Company Guides/X (Twitter)

X (Twitter) Interview Questions & Process for Software Engineers

The loop X actually runs now that engineering hiring goes through xAI: a written statement before anyone sees your code, and a proctored coding screen.

19 lessonsbuilt from 169 candidate reports

X (Twitter)
Alex Chen
Updated

01How the Twitter interview process works

Before anyone at X watches you write code, you have to write about the best code you have already written. The Statement of Exceptional Work goes in alongside your CV: one specific, high-impact thing you personally built, in your own words. It descends from the note Musk sent engineers in November 2022 asking them to summarize their recent commits, and it front-loads the whole process. The first gate is a writing gate. Everything after it belongs to xAI, which runs engineering hiring for the platform now, and the process tends to close inside two to three weeks.

The screen that follows is proctored. Camera and microphone stay on for the full sitting, the clock is what candidates complain about far more than the problems, and some pipelines swap it for a live pairing session on applied object-oriented design: iterators, key-value stores, caches. After the onsite the panel files written feedback and a debrief settles the hire and the level in one conversation. No hiring committee sits above that, though Musk is reported to keep the final sign-off, so an offer is not firm until that lands.

1
Application
2
Recruiter
3
Screen
OA or phone
4
Onsite
4–6 rounds
5
Debrief
6
Offer
Read the full process breakdown

02The X onsite loop

The two things that decide this loop are the ones almost nobody drills: designing a data structure, and keeping it correct once more than one thread touches it. The design round hands you a small stateful component to build from scratch, and your interface is graded as heavily as your implementation. Then it extends: make it thread-safe, then make it survive millions of concurrent queries. That extension is where a candidate with a spotless pattern catalog can still lose the round.

Round counts move with level and team, and reports vary at the edges. Interviewers pick their own questions, so the person you draw shapes the day more than any published rubric would suggest. Reports also disagree about whether the behavioral portion is a round of its own or a conversation folded into the day. Either way there is no values list to rehearse against, and one honest, specific answer to why you want to be here does more work than a stack of STAR templates.

CodingCore
Practical, medium-centered data-structure and algorithm problems, graded on clean, working code over trick-spotting
Data-structure designDesign
Build a small stateful component from scratch, with a clean API, correct edge cases, and attention to thread safety
System designScale
Design a large-scale service end to end, reasoning about access patterns, fan-out, partitioning, and failure
BehavioralCulture
Ownership, collaboration, and genuine interest in the product, anchored in how the team builds and operates
Read the full loop breakdown

03The X coding bar

The coding rounds are medium-dominant with a hard tail, and they are rarely lost on difficulty. The score comes from whether the thing you wrote would hold up in a running service: an interface you can defend, edge cases you found before the interviewer pointed at them, and shared state that does not corrupt when two threads reach it at once. Simple and correct beats clever and broken, and most people who lose here lose by reaching for the clever version.

Around those two sit the ordinary families: arrays, strings, and hashing; trees and graphs; heaps, top-K, and intervals; and dynamic programming. DP is there for breadth rather than specialization, so expect to see it once and do not build a month of prep around it. Candidates who do well state their complexity without being asked and walk the edge cases before anyone goes looking for them.

Coding roundtarget allocation
Clarify
Design the structure, write clean code
Test edges
Clarify the APIImplement and reasonEdge cases
Read the full coding breakdown

04X system design

The home timeline is the canonical system design question in the industry, and this is the company that produced it. That does not mean you are guaranteed to get it. Fan-out on write is the answer everyone arrives with, and it breaks the moment an account with ten million followers posts. The real system is a hybrid: timelines precomputed for ordinary accounts, the large ones merged in at read time. Knowing roughly where that threshold sits and being able to argue for it counts for more than naming another queue. The company open-sources the recommendation code behind that timeline as the-algorithm on GitHub.

The other worked designs sit on the same platform: trending topics as top-K over a firehose, a rate limiter, notifications and fan-out, and real-time search across billions of posts. The rate limiter earns extra attention, because it turns up in both eras of this company and because the public API here has long rate-limited with GCRA, a leaky-bucket variant that tracks one timestamp per key rather than a counter.

The strong answers start at the access patterns and the consistency requirements, then get concrete about fan-out, partitioning, and what happens when a shard dies. A tour of technologies with no trade-off attached to any of them reads as someone who has read about distributed systems rather than run one.

Read the full system-design breakdown

05X pay and offer

An X offer no longer involves public stock. Twitter was taken private in the 2022 buyout, its TWTR ticker was delisted, and the company folded into xAI in a 2025 all-stock deal, so the equity in an offer today is private xAI stock rather than anything you can price on a public market. That retires everything ever written about the old public-Twitter RSUs and replaces it with the usual private-company questions: what a share is worth, and when it turns into money.

LevelAvg total comp (US)
Software Engineer$183K
SWE II$249K
Senior SWE$341K
Staff SWE$507K

Historical Twitter-era average total comp by level, per Levels.fyi (US). Read this as a Twitter salary reference, not a current X offer: most reports predate the 2022 take-private, Levels.fyi still lists the delisted TWTR ticker and public RSUs, and X is now private under xAI. The aggregate median was about $223K; Senior Staff and above sit higher on very thin samples.

Reports from the Twitter era describe no annual bonus and no structured refresher program, and a private company under new ownership may run things differently, so ask rather than assume. If the initial grant and the sign-on carry the whole offer, that is exactly where a counter belongs.

The lever that works is a written offer from one of the labs bidding for the same small pool of engineers, and that competition is expensive enough to move a number here. Get the grant in specifics before you sign: the instrument, the share count, the valuation the price is struck against, the vesting shape, and any liquidity constraint on your shares, because a private grant is only worth what a future tender or event lets you sell it for.

Read the full offer & negotiation guide

06What Twitter actually asks

A handful of shapes keep coming back. Tweet Counts Per Frequency is the one with the company name attached, a bucketed counter you are asked to design rather than solve. Around it sit an in-memory database with nested BEGIN, COMMIT, and ROLLBACK, a thread-safe cache, Merge K Sorted Lists living inside any feed merge, and enough graph and DP work to cover breadth.

The questions that recur most
  • Design a thread-safe data structuredesign · #1
  • Design a rate limiter (GCRA)design
  • Design the home timelinesystem design
  • Two Sumarrays / hashing
  • Group Anagramshashing
  • Longest Substring Without Repeatingsliding window
  • a Premium question
  • Meeting Rooms IIheap / intervals
  • Number of Islandsgraphs / grids
  • a Premium question
  • Binary Tree Level Order Traversaltrees
  • Word Breakdynamic programming
  • a Premium question
  • Top K Frequent Elementsheaps
  • Design trending topics (top-K firehose)system design
  • Design a concurrent LRU cacheconcurrency
Recurring coding themes
What the loop keeps coming back to
01
Design a data structure
Stateful components, clean APIs, correct edge cases
02
Concurrency & thread safety
Locks, atomics, race-free shared state
03
Arrays, strings & hashing
Frequency maps, sliding window, string parsing
04
Trees & graphs
Traversals, hierarchies, connectivity
05
Heaps, top-K & intervals
Top-K, a Premium question, scheduling
06
Dynamic programming
Classic 1D and 2D DP, sequence problems
The behavioral questions X (Twitter) repeats
Read fast by an engineer, not a recruiter with a rubric
  • Why xAI? Why do you want to work here?Mission fit
  • What are you most excited to build here?Mission fit
  • Tell me about yourselfThe HM round, in one story
  • What is the project you are most proud of?Builder identity
  • Give an example of extreme ownershipOwnership
  • Describe your most stressful technical projectVelocity & intensity
  • A requirement or spec you challengedFirst principles
  • Something you removed, cut, or simplifiedFirst principles
  • Getting something done with no clear ownerFlat org
  • A technical decision you got wrongFailure & learning

The full set of X (Twitter) behavioral interview questions is grouped by the signal each one is after, or start with the STAR method.

Each of these X (Twitter) system design interview questions is a different shape, worked end to end in the guide.

Concurrency is what separates this loop from every other social-platform loop. The follow-up is nearly always the same move, take the thing that works and make it survive millions of concurrent queries, and candidates whose interview code has only ever been single-threaded stall right there...

Continue reading

The full breakdown. Every round and every pattern, with the strategy that goes with each.

Go to the Full Guide
Common questions

What are the stages of the Twitter interview process?

The Twitter interview runs through 6 stages: Application, Recruiter, Screen, Onsite, Debrief, and Offer.

How many rounds does the Twitter interview have?

The interviewing rounds sit in the onsite (4–6 rounds). The other stages (application, recruiter, and team match) are conversations, not scored rounds.

Is the X (Twitter) interview hard?

The coding is practical medium DS&A graded on clean working code, plus a data-structure design round that specifically probes thread safety. The distinctive weight is system design at Twitter and X scale: the home timeline, trending topics, and a rate limiter. Note the process changed under xAI, so expect a written statement before anyone sees your code and a proctored screen at the front of the funnel.

Does X (Twitter) ask LeetCode questions?

Yes, practical medium DS&A: design a data structure, concurrency and thread safety, arrays and hashing, trees and graphs, heaps and top-K, and dynamic programming. The design round asks you to build a small stateful component with a clean API and correct edge cases, with attention to thread safety.

What is X (Twitter) system design like?

The home timeline is the canonical question the industry took from this company. Fan-out on write is the naive answer, and it breaks the moment an account with ten million followers posts; the real system is a hybrid, precomputing timelines for ordinary accounts and merging the large ones in at read time. Other designs: trending topics as top-K over a firehose, a rate limiter (the public API has long used GCRA, a leaky-bucket variant), notifications and fan-out, and real-time search over billions of posts.

How has the X interview changed under xAI?

Engineering hiring now runs through xAI, and candidates report a written statement submitted before anyone reviews code, plus a proctored coding screen. The technical bar and the system-design emphasis carry over from the Twitter era, but the front of the funnel is stricter and more structured.

How long does the X (Twitter) interview process take?

Typically four to six weeks: a recruiter screen and a written statement, a proctored coding screen, then a virtual onsite of coding, the data-structure design round, system design, and behavioral, followed by a debrief.

What did Twitter pay, and how does X pay now?

Levels.fyi’s per-level averages for this company are mostly pre-2022 Twitter-era public-RSU numbers: roughly $183K for a Software Engineer, $249K for SWE II, $341K for Senior, and $507K for Staff, with an aggregate median around $223K. Treat those as a historical Twitter reference, since the TWTR ticker is delisted and X is now private under xAI, so a current offer is private equity you cannot price on a public market. Get the share count, the valuation the price is struck against, and any liquidity constraint in writing.