PropelrPropelr
PricingBlogSign Up Free
HomeBlogThe X Algorithm in 2026: What the Source Code Says

Table of Contents

  • What X released
  • The four components
  • The 15 things it predicts
  • The formula that is public
  • The weights that are not public
  • The real change: heuristics are gone
  • What this means for how you post
  • The demotion side
  • Myths the code doesn't support

Share

XTwitterContent StrategyPersonal BrandingSaaS Founders

The X Algorithm in 2026: What the Source Code Says

X open-sourced its Grok-powered algorithm in January 2026. What the code actually shows, and why the '27x reply weight' everyone cites isn't in it.

Propelr
July 29, 2026
12 min read
Share:
Table of Contents
  • What X released
  • The four components
  • The 15 things it predicts
  • The formula that is public
  • The weights that are not public
  • The real change: heuristics are gone
  • What this means for how you post
  • The demotion side
  • Myths the code doesn't support
Propelr

Grow your LinkedIn/X
audience now

AI-powered content creation and scheduling for LinkedIn & X.

Try Propelr for Free
Quick answer

X open-sourced its For You algorithm in January 2026 as xai-org/x-algorithm under Apache 2.0. It ranks posts with a Grok-based transformer that predicts 15 engagement outcomes and combines them into a weighted sum. The widely shared figures claiming replies are worth 27x a like appear nowhere in the released code — the scoring formula is public, the weight values are not.

Search for how the X algorithm works in 2026 and you'll find remarkably specific numbers. Replies are worth 27 times a like. A genuine conversation is worth 150 times. Engagement velocity carries a 1000x weight. Reports carry a −369x penalty.

These numbers are everywhere. They're also unsourced — and now that X has published the actual code, we can say something stronger: the released algorithm contains no such figures.

That's not a technicality. It's the difference between reading a system and guessing at one. Here's what the code actually shows.

An isometric layered pipeline where content candidates flow down through stacked ranking stages and emerge scored and ordered, representing how X's Grok-based transformer ranks posts for the For You feed

What X released

On 20 January 2026, X published the code behind its For You feed as a public repository, xai-org/x-algorithm, under the Apache 2.0 licence. It's written primarily in Rust with a Python machine-learning pipeline, and the release covers the logic used to recommend both organic posts and ads. TechCrunch reported the release alongside the regulatory pressure X was facing at the time.

This followed Elon Musk's October 2025 statement that X was "aiming for deletion of all heuristics within 4 to 6 weeks," with Grok reading "every post" to match users with content.

The 2023 open-sourcing was a partial release of a system that has since been replaced. This one describes the current architecture.

The four components

The four systems in X's released recommendation stack
FeatureRole
Home MixerOrchestration — assembles feed requests through a staged pipeline
ThunderIn-memory store of recent posts from accounts you follow
PhoenixRetrieval and ranking — the Grok-based transformer
GroxContent understanding — spam detection and policy classifiers

Thunder handles in-network content. It consumes a Kafka event stream to maintain per-user stores of recent posts from accounts you follow, enabling what the documentation describes as sub-millisecond lookups without hitting an external database. This is why your feed can surface a post from someone you follow seconds after publication.

Phoenix does the harder job — finding content from people you don't follow. It uses a two-tower architecture, where separate neural networks encode user features and candidate posts into embedding vectors, then retrieves relevant posts by similarity search. Notably, it uses hash-based embeddings rather than traditional learned embedding tables.

The ranking transformer is derived from Grok-1, adapted for recommendation. The documentation notes an important structural constraint: candidates cannot attend to each other, only to the user context. Each post is scored independently against you, which means your post isn't being penalised for the company it keeps in the candidate pool.

Grox runs classifiers for spam and policy enforcement — the layer that decides whether content is eligible at all.

The 15 things it predicts

This is the most useful part of the release, and it's concrete. The model outputs a probability for each of 15 actions:

P(favorite), P(reply), P(repost), P(quote), P(click), P(profile_click), P(video_view), P(photo_expand), P(share), P(dwell), P(follow_author), P(not_interested), P(block_author), P(mute_author), P(report)

Five of those are things creators rarely think about: profile_click, photo_expand, dwell, share, and follow_author.

P(dwell) and P(share) are worth sitting with. Dwell is time spent — a post that stops the scroll scores on a dimension no public metric shows you. Share means sending a post to someone privately, which is invisible in your analytics and, on most platforms, correlates strongly with content people find genuinely useful rather than merely agreeable.

P(follow_author) means the model is estimating whether a given post would make a stranger follow you. That's a different target from "would this get a like," and it favours posts that demonstrate something.

The formula that is public

The scoring step is stated plainly:

Final Score = Σ (weight_i × P(action_i))

And the sign convention:

"Positive actions (like, repost, share) have positive weights. Negative actions (block, mute, report) have negative weights."

Seven processing stages run per request, with ten pre-scoring filters removing ineligible content before any machine-learning prediction happens. Filtering comes first — being eligible is a precondition, not a ranking factor.

The weights that are not public

Here's the gap. The repository confirms that 15 coefficient values exist. It does not publish any of them.

As PPC Land put it in its analysis of the release: the code "reveals the existence of coefficient values for 15 engagement types but does not disclose actual numerical weights." There's no way to know from the public code whether replies carry a coefficient of 0.1, 1.0, or 10.0.

So where did 27x come from?

Not from this release. The figures circulating in 2026 round-ups trace back — where they're traceable at all — to community analysis of the 2023 codebase, which was a different system with hand-tuned constants. Those numbers have been recycled, relabelled as 2026 findings, and in several cases attributed to "X's open-source algorithm" by articles that never mention Grok, Phoenix, or Thunder.

One widely shared guide claims to have analysed X's open-source algorithm while describing a system that no longer exists. Several publish weight tables to two significant figures with no methodology, no sample size, and no link.

If a number describing X's current ranking weights has a source, that source is not the code. Treat precision as a warning sign, not a credential.

The real change: heuristics are gone

The most significant line in the documentation isn't about weights at all:

"We have eliminated every single hand-engineered feature and most heuristics from the system. The Grok-based transformer does all the heavy lifting by understanding your engagement history."

Plus: "No manual feature engineering for content relevance."

This is the change that matters for anyone posting on X, and almost nobody is writing about it.

The old system had explicit, hand-coded rules. Boost this, penalise that, decay by this factor. Those rules were what "algorithm hacking" targeted — you could find a lever and pull it, because the levers were literally written down as constants.

A transformer reading your post's content and your audience's engagement history doesn't have levers in the same sense. It has learned associations. There's no line of code saying "posts with links get 50% less reach" — if links underperform now, it's because the model learned that users don't engage with them, which is a much harder thing to game and a much easier thing to accidentally confirm.

The practical consequence: tactics that worked by exploiting a rule have a short shelf life, and tactics that make content genuinely engaging to your specific audience have a longer one. That sounds like a platitude until you notice it's a direct architectural consequence of removing hand-engineered features.

What this means for how you post

Four things follow reasonably from the released architecture. I've marked where I'm inferring rather than reporting.

Write for dwell, not just for likes. P(dwell) is one of 15 predicted actions. Posts that take a moment to read — a specific story, a numbered breakdown, a genuine argument — earn time on screen. One-line hot takes get a fast like and a fast scroll. This is reported: dwell is in the list.

Optimise for the private share. P(share) counts sending a post to someone. That rewards usefulness over agreeability. The test: would a reader forward this to a colleague? (Inference: share is a predicted action; its weight is unknown.)

Give strangers a reason to follow. P(follow_author) is scored per post. A post that demonstrates how you think converts better than one that asks for engagement. (Inference.)

Content is read directly now. Grok reads the post itself, so semantic relevance to your audience's interests is doing real work. Hashtags were a categorisation crutch for a system that couldn't understand text. That system is gone.

The one thing the code doesn't tell you is how many posts get considered or retrieved at each stage — the funnel numbers you'll see quoted (500 million posts narrowed to 1,500 candidates) aren't quantified in the documentation. Treat them as secondary reporting.

If you want the practical cadence and format side, our 2026 X growth playbook covers what to actually publish. Hook craft transfers across platforms too — the 12 hook formulas we wrote for LinkedIn apply almost unchanged to the first line of a post.

The demotion side

Five of the 15 predicted actions are negative: not_interested, block_author, mute_author, report, and — depending how you read it — the absence of positive engagement.

Negative signals carry negative coefficients and actively demote content the model expects users to reject. Creators consistently underweight this. Engagement-bait, rage-bait, and follow-for-follow tactics can produce positive engagement while also raising your predicted mute and block probability. The score is a sum, and one side of it is working against you.

There's a structural asymmetry here: a block is a much rarer event than a like, so a model trained to predict it is predicting something with far more information per occurrence. You don't need many people muting you for that to matter.

Myths the code doesn't support

"Replies are worth exactly 27 likes." No weight values are published. Replies are one of 15 predicted actions with an undisclosed coefficient.

"There's a hard six-hour reach half-life." No time-decay constant appears in the released documentation. Recency plainly matters — Thunder exists specifically to serve recent in-network posts fast — but a specific half-life is not in the code.

"Premium gives you a 4x to 8x reach boost." No such multiplier appears in the release. Account-level signals may well be learned features, but the specific multipliers circulating have no published basis.

"Links are penalised by 50%." No hard-coded link penalty appears, and P(click) is a positive predicted action. Given that hand-engineered features were removed, a fixed link penalty would contradict the stated architecture. Links may still underperform through learned behaviour — that's a different mechanism with different implications.

"Hashtags trigger spam filters above three." Not in the code. Grox handles spam classification; no hashtag threshold is documented.

The honest summary: X published its architecture and its scoring formula, and withheld its coefficients. Anyone quoting precise weights for 2026 is either working from the superseded 2023 release or making them up.

Frequently asked questions

Did X really open source its algorithm in 2026?
Yes. On 20 January 2026, X published the code behind its For You feed as xai-org/x-algorithm under the Apache 2.0 licence, written mainly in Rust with a Python machine-learning pipeline. The release covers the logic used to recommend both organic posts and advertisements.
Are replies really worth 27 times a like on X?
There is no published basis for that figure. The released code confirms that weight coefficients exist for 15 predicted engagement actions but does not disclose any of their values. Figures like 27x appear to derive from community analysis of the superseded 2023 codebase, which was a different system using hand-tuned constants.
What does the X algorithm actually optimise for?
It predicts the probability of 15 actions for each post and combines them into a weighted sum. The actions are favorite, reply, repost, quote, click, profile click, video view, photo expand, share, dwell, follow author, not interested, block author, mute author, and report. The final five are negative signals that demote content.
What is Phoenix in the X algorithm?
Phoenix is the component that handles both retrieval and ranking of out-of-network content. It uses a two-tower architecture to encode users and posts as embeddings for similarity search, then ranks candidates with a transformer derived from xAI's Grok-1 model, adapted for recommendation.
Do hashtags still work on X in 2026?
They are no longer needed for discovery. The Grok-based transformer reads post content directly, so categorising your content with hashtags addresses a problem the current system does not have. No hashtag penalty is documented in the released code either, so the claim that more than two or three triggers a spam filter has no published basis.
Does X Premium boost your reach?
The released code contains no Premium reach multiplier, so the widely quoted 2x to 8x figures have no published basis. Account-level signals may be learned features within the model rather than explicit rules, but the specific multipliers circulating in 2026 guides are not supported by the source code.

The genuinely useful takeaway is architectural rather than tactical: with hand-engineered features removed, there are fewer rules left to exploit, and content quality relative to your specific audience is doing more of the work. If your X and LinkedIn output is the constraint, Propelr drafts in your own voice across both. And if you're rebuilding your X stack after Hypefury dropped X support, that audit covers the current tooling options.

P
Written by
Propelr

Content and growth research team at Propelr

The Propelr team publishes playbooks from inside a content platform used to create, schedule, and analyze thousands of LinkedIn and X posts. Articles are grounded in real usage data and current platform behavior, not recycled advice.

linkedin.comx.com

Keep reading

All posts
13 min read·X

Hypefury Alternatives 2026: It Dropped X. Now What?

Hypefury no longer supports X and now costs $6/mo. An honest 2026 guide to what X-first creators should switch to — and who should stay put.

9 min read·X

X Growth in 2026: Attention, Influence & Search Playbook

X growth in 2026: the algorithm, the analytics, viral tweet timing, and a daily cadence — the practical playbook that works without paid ads.

12 min read·LinkedIn

How to Get Your LinkedIn Posts Cited by ChatGPT (2026)

LinkedIn is the #1 cited domain for professional queries in AI search. What three studies of 2.7M+ citations reveal about getting your posts quoted.

Back to all postsTry Propelr Free
Propelr

Grow your LinkedIn/X
audience now

AI-powered content creation and scheduling for LinkedIn & X.

Try Propelr for Free