The method and result come from our experiment of October 2017. We have not repeated it since. What has changed in search and tools is covered in the section What has changed since?
- Today Google connects words with concepts through systems such as RankBrain, neural matching and BERT. Pages therefore rank even without the exact phrase, and on-page features such as “phrase in the title” explain rankings less than in 2017.
- In 2017 we wanted to know for which of 3,600 keywords a simple on-page optimization would be enough for a top 10 position. Keyword data from the SEMrush API and crawled on-page features (phrase in title, content, URL path, domain) trained a neural network, an MLPClassifier from scikit-learn.
- For around 600 of the 3,600 keywords, the model predicted a top 10 position after optimizing title and content. Irrelevant terms got no prediction. Some of the forecasts were too optimistic.
The question behind the experiment
Finding keywords is easy, assessing them is not. For our example website, a niche shop on raw feeding for dogs (BARF), SEMrush returned more than 1,100 keywords it already ranked for. With the competitors' keywords, there were more than 3,600. For a larger website that is not many, yet it is still too many to check by hand.
We wanted to know for which of these keywords a top 10 position could be reached with little effort. To do this, we trained a machine learning model that predicts the position after an on-page optimization. We first presented the experiment at SEO Day 2017.
Method in five steps
1. Think about how you would do it by hand
By hand you would look at search volume and CPC. High values suggest a lot of competition. If a very similar competitor ranks in the top 10, that is probably achievable for your own page too. If your own page is already well optimized but ranks on page two or three, more on-page work brings little. If there is no matching page or it is poorly optimized, the potential is greater. This is exactly the data the model gets.
2. Collect and convert the data
Via the SEMrush API we retrieved all keywords of the example site and its competitors. We then crawled every ranking page and checked whether the keyword phrase appears in the title, content, URL path or domain. The model only processes numbers. That is why we also encoded domains and keywords as numbers.
| Feature | Meaning | Values |
|---|---|---|
| Search volume, CPC | Competitive situation of the keyword | Number from SEMrush |
| Domain, keyword | Who ranks for what | encoded as a number |
| title_found | Words of the phrase in the title | 1 = all, 0.5 = half, 0 = none |
| content_found | Words of the phrase in the content | 1 / 0.5 / 0 |
| path_found, domain_found | Words of the phrase in URL path and domain | 1 / 0.5 / 0 |
| Position | Target value the model learns | current position |
3. Train the model
We split the data into 80% training data and 20% test data. The algorithm was an MLPClassifier, a neural network from scikit-learn. In our tests a neural network worked best for this task. Training can take minutes or hours. This simplified example shows the principle.
4. Predict positions for optimized pages
For the keyword “barf fleisch kaufen” (buy BARF meat), the phrase was missing from the shop page's title and URL. It appeared partly in the content and in the domain. The model predicted position 20. In the test data, the page was at position 18. We then entered the same data with the phrase in the title and content. The model predicted position 1.
5. Evaluate all keywords
The same ran for all 3,600 keywords. For terms unrelated to the shop, such as “kreuzberg”, “durchfall” (diarrhea) or “ziege” (goat), the model gave no prediction. That speaks for its quality, because a good ranking is not to be expected for such terms either. Filtered to predicted positions below 10, around 600 mostly relevant keywords remained.
Result
| Metric | Value |
|---|---|
| Keywords of the example site according to SEMrush | more than 1,100 |
| Keywords including competitors | more than 3,600 |
| Keywords with a predicted top 10 position after optimization | around 600 |
| Example “barf fleisch kaufen”, prediction vs. actual | Position 20 vs. 18 |
| Same keyword, optimized in title and content | predicted position 1 |
Instead of checking 3,600 keywords by hand, this produced a list of 600 candidates for new or optimized pages. Some of them were misses, and some forecasts were too optimistic. As a starting point for the on-page work, the list did its job. Whether the pages actually ranked that way after optimization is something we did not measure as part of the experiment.
Limitations of the experiment
- Only a few on-page features, mainly the position of the phrase in title and content. External links and analyses such as TF*IDF were missing.
- One niche website with 3,600 keywords. More ranking data, more competitors and more keywords should improve the prediction.
- We did not systematically optimize parameters and algorithm.
- A classifier treats every position as a separate class. A regression that knows the distances between positions would be an obvious comparison (our assessment, not tested).
What has changed since?
The method is nine years old. Three things have changed considerably since then.
- Google understands language better. According to Google, systems such as RankBrain, neural matching and BERT now work on connecting words with concepts. Pages can therefore rank even without the exact phrase (Google documentation as of 10 December 2025). A feature such as “all words in the title” therefore explains rankings less than in 2017.
- The results page is fuller. According to Google, AI Overviews and AI Mode build on the same ranking systems. A position on its own, however, says less about clicks than it used to when there is an AI overview above it.
- Tools are more accessible. scikit-learn with the MLPClassifier still exists. The code of our experiment is publicly available in the repository searchVIU Labs on GitHub, together with an example that predicts the CTR per position from Search Console data.
The basic idea remains useful. If you want to prioritize keywords by potential, combine competitive data with what is on your pages and let a model pre-sort the list.
Common mistakes when rebuilding it
- Test and training data overlap, and the model appears more accurate than it is.
- The prediction is read as a promise. It is a ranking for checking by hand.
- Keywords unrelated to the offer stay in the list because nobody looks through the results.
Frequently asked questions
Can Google rankings be predicted with machine learning?
Roughly, yes. A model learns from competitive and on-page data which positions are realistic for a keyword. In our 2017 experiment, the prediction in the example was two positions away from the real value. That is enough for pre-sorting, not for a promise.
What data does a model need to predict rankings?
We used search volume, CPC, ranking domains and keywords, and the position of the phrase in title, content, URL path and domain. External links and content analyses would probably improve the prediction.
Which algorithm is suitable?
We used an MLPClassifier from scikit-learn, a neural network that performed best in our tests. We did not systematically compare other methods.
Is the experiment still meaningful today?
As a method, yes. The figures, however, apply to 2017 and a niche website. Today Google classifies words more by concept. That is why we would add further features and check the result again.
Where can I find the code?
In the public repository searchVIU Labs on GitHub, as Python code in Jupyter notebooks.
Sources
Retrieved on October 15, 2026. If something is out of date or missing, let us know.
- scikit-learn, MLPClassifier: https://scikit-learn.org/stable/modules/generated/sklearn.neural_network.MLPClassifier.html
- Semrush, API: https://developer.semrush.com/api/
- Google Search Central, A guide to Google Search ranking systems: https://developers.google.com/search/docs/appearance/ranking-systems-guide · As of Dec 10, 2025
- Google Search Central, Google's Guide to Optimizing for Generative AI Features on Google Search: https://developers.google.com/search/docs/fundamentals/ai-optimization-guide · As of Jul 10, 2026