Blog Migration Between Two Joomla Sites with Translation
Summary
Needed to move a blog from a Russian site to an English one: two independent Joomla 6.1.2 installations, 587 articles with formatting, tags, dates, and images. I assembled a pipeline of scripts: export and cleanup, translation via DeepSeek, publication via API, and automatic repair of internal links.
Technology Stack
| Technology | Role |
|---|---|
| Joomla 6 (Web Services API) | Source and recipient of articles |
| Cherry Studio + DeepSeek | Translation, generation of SEO texts |
| Python | Pipeline and link repair scripts |
| xlsx tracker | Progress tracking for 596 articles |
| Site Analizer | Broken link search |
Context and Task
Two studio sites on Joomla 6.1.2: a Russian and an English one. The task was to move all blog articles from the /blog section of the Russian site to /blog of the English one. The configuration and CMS are the same, but these are two independent installations: no shared databases, media libraries, or keys between them.
A blog article is not just text. It has a publication date, tags, HTML formatting, and images. The volume is 587 articles. Doing this manually would take months of monotonous work, so automation was the only way.
Solution: Pipeline of Small Scripts
Instead of one big script, a chain of small ones, each responsible for its own stage:
02_translate.py — translation of articles and generation of meta tags ([DeepSeek](../glossary/deepseek.md))
04_publish.py — publication in [Joomla](../glossary/joomla.md) via [API](../glossary/api.md)
05_inspect_4seo_schema.py — reconnaissance of 4SEO tables (for meta tags)
06_update_tracker.py — update of xlsx tracker
07_set_meta.py — meta tags in 4SEO (separate case)
08_fix_internal_blog_links.py — repair of internal blog links
Stage 1. Audit: From Scanner Export to Working Tracker
First, understand what exactly needs to be moved. The export from the scanner turned out to be a chaotic set of data: 764 URLs, including /images/... images and dozens of SEO columns — response time, robots.txt, external links. None of this is needed for the migration.
After cleaning, 596 blog article pages remained, along with only useful fields: URL, alias, title, meta description, word count. Along the way, a probable duplicate was found: /blog/geo-kon and /blog/geo-au had the same title — marked for manual verification to avoid moving the same article twice.
Another 9 articles were put on hold for manual verification. The result is 587 articles.
Important detail: the scanner does not export the publication date, category, tags, and HTML body of the article. This had to be checked separately in the Joomla admin panel.
In the end, an xlsx tracker with 596 rows was created: RU-data (do not touch), status for each article, EN-data (fill in as you go), notes.
Stage 2. Tags — Translate in Advance, Not On-the-Fly
If the translation of tags is handed over to the AI for each article separately, the same Russian tag may be translated differently in different requests: 'Promotion' one time, 'Digital Promotion' another. This leads to inconsistencies in tags across articles. Correctly — translate the tags once before starting. There were few tags, so I translated them manually. During the migration, tags are taken strictly from the prepared list, not generated anew.
Stage 3. Translation: Markup Unchanged
Translation went through Cherry Studio + DeepSeek. For each article, the model in one request:
- translates the title and alias (slug) to English;
- translates the HTML body while preserving the markup — tags <p>, <h2>, <a href> are untouched, only the text inside is translated;
- translates image alt texts;
- replaces internal links according to a prepared mapping;
- generates SEO title (up to ~60 characters) and meta description (up to ~155–160) in English — these were useful for 4SEO on the next stage.
The response format is JSON, so it can be uploaded automatically, not copied by hand.
Stage 4. Publication via API
Articles are published via Joomla Web Services (API). Each is created with a title, alias, body, category, tags, and date. Special solution — publication date: preserve the original (for blog chronology) or set the current (to make the English blog look fresh). The choice depends on the goals, not the technology. Images: there are no shared media libraries, so images are downloaded from the Russian site and uploaded to the media library of the English site.
Problems Encountered
1. Custom Link Checker Crashed
The find_broken_links.py script checked 381 links one by one, with a wait of up to 15 seconds per link. In the worst case, it took over an hour. It turned out that a full SEO scanner (Site Analizer) had already provided a more complete picture: 41 broken links. Of these, only 22 related to the blog migration (20 blog links + 2 to service pages), the rest 19 were images in /images/about/, outside the scope of this migration.
2. Internal Links Pointed to Old Russian Aliases
When translating href inside links, it was intentionally left untouched to avoid breaking the structure. But there was a nuance: some links inside articles pointed to other articles of the same blog. After the move, each article got a new English alias — and links to old Russian aliases became broken.
The RU-alias → EN-alias correspondence had been lying in translated_articles.json — a ready-made mapping for automatic repair. So, links are fixed automatically, by one script, without manual work.
Solution
Script 08_fix_internal_blog_links.py:
- finds links to old Russian aliases of other blog articles in published articles;
- replaces them with correct English ones according to the prepared mapping;
- updates articles directly on the site via API — selectively, only the text field.
First test on 5 articles with --debug, then on all. Manually left only 2 links to service pages — there the solution is by substance, not by algorithm.
Final Diagram
flowchart LR
A["Scanner Export\n764 URLs"] --> B["Cleaned to 596 articles\nxlsx tracker"]
B --> C["02_translate.py\nDeepSeek: translation + meta tags"]
C --> D["04_publish.py\nJoomla API"]
D --> E["08_fix_internal_blog_links.py\nRU-alias replacement with EN"]
E --> F["587 articles on the new site"]
Result
587 articles were moved with translation: titles, aliases, formatting, tags, and meta tags. Blog internal links were automatically fixed using the already prepared RU→EN mapping, not manually. Meta tags in 4SEO were set by a separate script — this is the next case.
What I Learned
- Audit before migration. Out of 764 URLs in the export, only 596 were real articles, and among them was a duplicate. Better to find this before migration than after.
- Translate tags in advance, in bulk. Otherwise, one tag turns into several translation variants.
- Do not touch markup during translation. Translate only the text inside tags — the structure will not be harmed.
- Alias mapping saves the day. The RU→EN correspondence was already in the file, all that was left was to write a script to apply it.
- Do not write your own checker if a ready-made scanner exists. Site Analizer provided a more complete result faster.
What's Next
- 2 links to service pages — resolve manually, where to point them.
- 9 postponed articles — verify manually.
