Twitter / X
Real-time social platform with petabyte-scale data and ML ranking systems.
4 Rounds
~14 Days
Hard
The Interview Loop
Recruiter Screen (30 min)
Standard fit check, behavioral questions, and resume overview.
Technical Loop (3-4 Rounds)
Deep dive into domain knowledge, coding, and system design.
Interview Question Bank
Backend Engineer
•
System Design
•
medium
Design a Distributed ID Generator (like Snowflake) to generate unique IDs for tweets at a massive scale.
#Distributed Systems
#ID Generation
#Concurrency
Backend Engineer
•
System Design
•
medium
Design the 'View Count' feature for tweets that was recently rolled out. How do you ensure high throughput and low latency without overwhelming the database?
#Caching
#Event Sourcing
#Data Aggregation
Backend Engineer
•
System Design
•
hard
Design the 'For You' timeline. How do you mix algorithmic recommendations with tweets from people the user follows?
#Recommendation Systems
#Fan-out
#Machine Learning Infrastructure
Backend Engineer
•
System Design
•
hard
Design the backend for Community Notes. How do you handle concurrent edits, version history, and fast retrieval?
#Concurrency Control
#Database Design
#Eventual Consistency
Backend Engineer
•
System Design
•
medium
Design Twitter's URL shortener (t.co). Focus on high availability and analytics tracking.
#Hashing
#Database Sharding
#Analytics
Backend Engineer
•
System Design
•
hard
Design a real-time spam/bot detection system that evaluates tweets as they are published.
#Stream Processing
#Machine Learning
#Rules Engine
Backend Engineer
•
System Design
•
hard
Design the Direct Message (DM) system. How do you handle real-time delivery, read receipts, and offline users?
#WebSockets
#Pub/Sub
#Database Design
Backend Engineer
•
System Design
•
hard
Design a notification system that sends push notifications to millions of users simultaneously when a major news event occurs.
#Push Notifications
#Queueing
#Scalability
Backend Engineer
•
System Design
•
medium
Design a system to securely store and serve media (images/videos) uploaded by users.
#Blob Storage
#CDN
#Media Processing
Backend Engineer
•
System Design
•
hard
Design a distributed rate limiter for the X API to handle different tiers of users (Free, Basic, Pro) with varying limits.
#Distributed Systems
#Rate Limiting
#Redis
Cloud Engineer
•
System Design
•
medium
Design a distributed caching layer for trending topics that can handle extreme traffic spikes (e.g., during the Super Bowl or a major global news event).
#Caching
#Redis
#Memcached
#Thundering Herd
Cloud Engineer
•
System Design
•
hard
Design the cloud infrastructure to support Twitter's timeline generation at scale, ensuring sub-200ms latency for 500 million daily active users.
#Scalability
#Caching
#Load Balancing
#Microservices
Cloud Engineer
•
System Design
•
hard
Design a global rate-limiting service for the X API that can handle millions of requests per second across multiple geographic regions.
#Rate Limiting
#Distributed Systems
#Redis
#Concurrency
Data Engineer
•
System Design
•
hard
Design an ad-click attribution pipeline that handles late-arriving events and ensures exactly-once processing.
#Exactly-Once Semantics
#Watermarks
#Data Pipelines
Data Engineer
•
System Design
•
hard
Architect a streaming system to detect spam and bot activity in real-time as tweets are published.
#Machine Learning Pipelines
#Real-time Streaming
#Feature Engineering
Data Engineer
•
System Design
•
hard
Design a data lake architecture for storing, partitioning, and querying 10PB of daily tweet logs efficiently.
#Data Lake
#Partitioning
#Parquet
#Iceberg/Hudi
Data Engineer
•
System Design
•
hard
How would you design the batch and streaming data pipelines to generate features for the 'For You' timeline recommendation engine?
#Feature Store
#Lambda Architecture
#Graph Processing
Data Engineer
•
System Design
•
hard
Design the data pipeline for Twitter's View Count feature, ensuring real-time updates and high throughput.
#Stream Processing
#Kafka
#Redis
#Event Sourcing
Data Engineer
•
System Design
•
hard
Design a real-time trending topics system capable of processing millions of tweets per second.
#Heavy Hitters
#Stream Processing
#Distributed Systems
Data Engineer
•
System Design
•
hard
How would you architect the migration of a massive on-premise Hadoop cluster to GCP BigQuery with zero downtime?
#Cloud Migration
#BigQuery
#Dual Writes
#Data Validation
DevOps Engineer
•
System Design
•
hard
Design the caching layer for the X timeline using Redis to handle millions of concurrent reads and thousands of writes per second.
#Redis
#Caching
#High Throughput
#Data Modeling
DevOps Engineer
•
System Design
•
hard
Design a multi-region Kubernetes cluster architecture for X's timeline service to ensure 99.99% uptime, even if an entire region goes offline.
#Kubernetes
#High Availability
#Disaster Recovery
#Global Load Balancing
DevOps Engineer
•
System Design
•
hard
We are moving away from managed cloud services to self-hosted solutions to save money. How would you design a highly available, self-hosted Kafka cluster across 3 data centers?
#Kafka
#Distributed Systems
#Bare-metal
#High Availability
DevOps Engineer
•
System Design
•
hard
Explain how you would implement aggressive auto-scaling for stateless microservices to handle sudden viral events (like the Super Bowl) while minimizing idle compute costs.
#Auto-scaling
#KEDA
#Kubernetes
#Cost Optimization
DevOps Engineer
•
Technical
•
medium
Explain the difference between eventual consistency and strong consistency. Give an example of where you would use each within X's architecture.
#Distributed Systems
#CAP Theorem
#Databases
Full Stack Engineer
•
Behavioral
•
hard
What is the most complex system you have built from scratch, and what were the key technical trade-offs you had to make?
#Architecture
#Trade-offs
#End-to-End Ownership
Full Stack Engineer
•
System Design
•
hard
Design a real-time Direct Messaging (DM) system for X, supporting 1-on-1 and group chats with read receipts.
#WebSockets
#NoSQL
#Real-time
#Pub/Sub
Full Stack Engineer
•
System Design
•
hard
Design X's Trending Topics system. How do you calculate trends in real-time across different geographic regions?
#Stream Processing
#Apache Kafka
#Count-Min Sketch
#Distributed Systems
Full Stack Engineer
•
System Design
•
hard
Design a system to detect and filter out spam or bot replies in real-time before they are rendered to users.
#Machine Learning
#Stream Processing
#Rules Engine
Full Stack Engineer
•
System Design
•
hard
Design the architecture for X Spaces (live audio rooms). How do you handle thousands of listeners and multiple speakers with low latency?
#WebRTC
#Audio Streaming
#SFU
#Scalability
Full Stack Engineer
•
System Design
•
hard
Design an ad-serving system for the X feed. How do you select the most relevant ad in under 50ms?
#Machine Learning Inference
#Low Latency
#Auction Algorithms
Full Stack Engineer
•
System Design
•
medium
Design a search system to find specific tweets by a user within a specific date range.
#Elasticsearch
#Inverted Index
#Data Partitioning
Full Stack Engineer
•
System Design
•
medium
Design X's push notification system. How do you ensure notifications are delivered reliably and not duplicated?
#Message Queues
#APNs/FCM
#Idempotency
Full Stack Engineer
•
System Design
•
hard
Design a video upload and processing pipeline for X. Users can upload up to 2 hours of 1080p video.
#Blob Storage
#Asynchronous Processing
#CDN
#Video Encoding
Full Stack Engineer
•
System Design
•
hard
Design the X Home Timeline. How do you ensure sub-second latency for users with millions of followers?
#Fanout
#Caching
#Message Queues
#Database Sharding
Full Stack Engineer
•
System Design
•
hard
Design the Like and Retweet counter system. How do you handle the massive write load when a tweet goes viral?
#Eventual Consistency
#Batching
#Distributed Counters
Machine Learning Engineer
•
System Design
•
medium
Design a multimodal model architecture to classify NSFW content in tweets containing both text and images.
#Multimodal ML
#Computer Vision
#NLP
#Classification
Machine Learning Engineer
•
System Design
•
hard
Design the 'For You' timeline ranking system. How do you balance engagement metrics like retweets and likes with negative signals like 'show less often'?
#Recommendation Systems
#Ranking
#Architecture
#Real-time ML
Machine Learning Engineer
•
System Design
•
hard
How would you design a real-time bot detection system for Twitter?
#Anomaly Detection
#Streaming Data
#Classification
#Graph ML
Machine Learning Engineer
•
System Design
•
hard
Design an Ad Click-Through Rate (CTR) prediction model. How do you handle delayed feedback when users click an ad hours after viewing it?
#Ads Ranking
#CTR Prediction
#Data Pipelines
Machine Learning Engineer
•
System Design
•
medium
Design a distributed counter system for Tweet views that can handle millions of concurrent updates.
#Distributed Systems
#Scalability
#Caching
Machine Learning Engineer
•
System Design
•
hard
Design the autocomplete and relevance ranking system for Twitter Search.
#Search
#Information Retrieval
#Tries
#Ranking
Machine Learning Engineer
•
System Design
•
medium
Design a system to recommend 'Who to Follow' to a user.
#Recommendation Systems
#Graph ML
#Batch Processing
Machine Learning Engineer
•
System Design
•
hard
Design a system to extract and rank trending topics in real-time across multiple languages.
#NLP
#Stream Processing
#System Architecture
Machine Learning Engineer
•
System Design
•
hard
Design a system to serve Grok (LLM) responses to users in real-time while maintaining the context of their recent tweets and timeline.
#LLMs
#System Architecture
#RAG
#Real-time ML
Product Manager
•
System Design
•
hard
Design a system to support X's trending topics. How do you ensure it is real-time, localized, and resistant to manipulation?
#Algorithms
#Real-time Systems
#Data Processing
Product Manager
•
System Design
•
hard
Design the backend for Community Notes to ensure real-time updates and consensus calculation across millions of users.
#Real-time
#Distributed Systems
#Algorithms
Product Manager
•
System Design
•
hard
Design a system to handle viral spikes (e.g., Super Bowl, Election Night) to ensure X stays online and responsive.
#Scalability
#Load Balancing
#Infrastructure
Product Manager
•
System Design
•
hard
Design a system to detect and filter out spam in X Direct Messages in real-time.
#Spam Detection
#Real-time
#Machine Learning
Product Manager
•
System Design
•
hard
Design the backend architecture for X Spaces (live audio) to support 1 million concurrent listeners in a single room.
#Audio
#Scalability
#Real-time Systems
Product Manager
•
System Design
•
medium
Design a rate-limiting system to prevent malicious bots from scraping X's API while allowing legitimate enterprise partners uninterrupted access.
#API
#Security
#Infrastructure
Product Manager
•
System Design
•
hard
Design the high-level architecture for X's 'For You' timeline recommendation engine.
#Machine Learning
#Recommendation Systems
#Scalability
Software Engineer
•
System Design
•
hard
Design the X 'For You' timeline, focusing on how to handle the fan-out problem for users with millions of followers.
#Scalability
#Caching
#Graph Processing
#Stream Processing
Software Engineer
•
System Design
•
hard
Design a system to detect and mitigate bot swarms liking a specific tweet in real-time.
#Machine Learning Infrastructure
#Anomaly Detection
#Stream Processing
Software Engineer
•
System Design
•
hard
Design an Ad Click Aggregation system that processes billions of events per day and provides real-time analytics to advertisers.
#Big Data
#OLAP
#Exactly-once Semantics
Software Engineer
•
System Design
•
medium
Design the Community Notes feature, including the data model for contributors, ratings, and the algorithm pipeline to display the most helpful note.
#Data Modeling
#Graph Algorithms
#Event Driven
Software Engineer
•
System Design
•
hard
Design X Search. How would you index tweets to allow full-text search within seconds of posting?
#Search Engines
#Inverted Index
#Real-time Indexing
Software Engineer
•
System Design
•
hard
Design a push notification system that alerts millions of users within seconds when a highly followed account posts a new tweet.
#Pub/Sub
#WebSockets
#Mobile Push
Software Engineer
•
System Design
•
hard
Design a View Count system for tweets that updates in near real-time and handles viral spikes without overwhelming the database.
#Event Aggregation
#Caching
#Database Sharding
Software Engineer
•
System Design
•
medium
Design Snowflake: A distributed unique ID generator for tweets that is highly available and sortable by time.
#Distributed Systems
#Bit Manipulation
#High Availability
Software Engineer
•
System Design
•
hard
Design the Trending Topics system. How do you process millions of tweets per minute to find top hashtags in real-time?
#Stream Processing
#Heavy Hitters
#Data Pipelines
Software Engineer
•
System Design
•
medium
Design a distributed rate limiter for the X API to prevent abuse while allowing burst traffic for premium (X Premium) users.
#Distributed Systems
#API Design
#Concurrency
Difficulty Radar
Based on recent AI-sourced data.
Meet Your Interviewers
The "Standard" Interviewer
Senior EngineerFocuses on core competencies, system constraints, and clear communication.
SimulateUnwritten Rules
Think Out Loud
Always explain your thought process before writing code or drawing architecture.