Kolkata ·  
AI engineering
retrieval
short · 3 min

Reciprocal rank fusion

Merging ranked lists using only each document's position in them, never its score.

updated 27 Sept 2026

Two searches, one query. The keyword search returned A, B, C, D. The vector search returned F, A, B, C. We want one list. Who goes first?

F topped one list. A was near the top of both. And we can't look at the scores to decide, because a keyword score and a vector score live on different scales and can't be compared (that's the whole problem in hybrid search). Positions, though, can always be compared. First is first.

Reciprocal rank fusion, RRF, merges lists using only those positions.

The formula

Each list gives each document in it some points: one over a constant kk plus the document's rank there. Add up the points across lists and sort.

RRF(d)=∑lists r1k+rankr(d)\text{RRF}(d) = \sum_{\text{lists } r} \frac{1}{k + \text{rank}_r(d)}

Ranks start at 1, and a document missing from a list gets nothing from it. The 2009 paper that introduced it set k=60k = 60 in a pilot run and never changed it.

Let's score our two lists at k=60k = 60:

DocumentKeyword rankVector rankk = 60k = 1
A120.03250.833
B230.03200.583
C340.03150.450
Fmissing10.01640.500
D4missing0.01560.200

At 60, the documents both searches found come first, and F, top of the vector list, ends up fourth. Look at the last column, though. At k=1k = 1, F jumps above C.

What k is doing

kk sets how much the top of a list outweighs the rest. At k=60k = 60, rank 1 gets 161\frac{1}{61} and rank 10 gets 170\frac{1}{70}, so first place is worth only 1.15 times tenth. Just being in the list matters almost as much as where. At k=1k = 1 it's 12\frac{1}{2} against 111\frac{1}{11}, 5.5 times, and the top few places dominate. So a low kk trusts one list's strong opinion. A high kk rewards the lists agreeing.

The price of using ranks: RRF can't tell whether first place won by a mile or by a hair. In return it needs no training data and no statistics about the collection.

So is 60 right?

In the original tests, which merged 30 search systems, it barely mattered:

Anything from about 20 to 100 landed within a whisker of the best, and every value beat the best single system (0.2016).

Hybrid search merges just two lists, and there kk matters more. Qdrant tried it on five public datasets in 2026, and the best kk ranged from about 1 to 60. It tracked one thing: how many right answers each query has. About one per query, small kk won. Tens or hundreds, large kk won. On one dataset, switching from a small kk to 60 changed the top result for 42% of queries.

Not every engine counts the same way. Qdrant numbers positions from 0, so its default k=2k = 2 means k=1k = 1 in the formula above, and to match the paper's 60 you set 61. And at low kk, documents tie more often (12.5% of top-10 results on one dataset, against 2.8% at 61). Qdrant returns ties in whatever order storage gives, so the same query can come back shuffled. Break ties yourself, by score and then by document ID.

So, back to F. Should one list's favourite beat a document both lists liked? With k=60k = 60, no. With k=1k = 1, yes. If your queries usually have one right answer, F's case is stronger. Start at 60, and if you have labelled queries, try a few smaller values and see which your data prefers.

Further reading