Author:
    Creation:2026-12-04Last update:2026-12-04

    Why consider migrating from Paraglide JS in 2027?

    Paraglide JS was one of the i18n libraries TanStack pointed people to. The official TanStack Router i18n guide and the start-i18n-paraglide example are both built on it.

    On November 16, 2026, Paraglide JS joined General Translation (GT). It stays MIT-licensed and existing apps keep working. But the direction has changed: the Paraglide README now recommends General Translation to translate your message files, and GT suggests its own SDKs, gt-react or gt-next, if you want the copy back in your components.

    The risk is that Paraglide's maintenance degrades over the coming months. The announcement says the project is now maintained by the GT team, but it does not say that its creator joins GT. Nobody from Inlang (the company behind Paraglide.js) joined GT, since almost all of Paraglide's past core developers have already moved on to other companies. Moreover GT already has its own SDK to push, which is still far from mature in December 2026 (see below). Bug and security fixes are promised. The roadmap, though, points to GT's translation CLI, dashboard and inference. Downloads already show it: weekly npm downloads of @inlang/paraglide-js went from 1.51 million (November 7 to 13) to 1.32 million (November 27 to December 3), about 13% fewer. The US Thanksgiving week falls in the second window, so part of the drop is seasonal.

    This guide is for you if you'd rather not depend on a company whose business is selling translations. Intlayer generates your translations for free, on your machine, with your own API keys (OpenAI, Anthropic, Mistral...) or a local model running in Ollama or LM Studio.

    What Paraglide Got Right

    Paraglide compiles every message into its own JavaScript function (m.hero_title()). A page only imports the functions it calls, so the bundler can drop the messages of the other pages. In the TanStack Start benchmark, Paraglide leaks 0% of other pages' content, where most libraries ship one big JSON per locale.

    What It Costs

    Each message function imports the text of every locale:

    paraglide/messages/_index.js
    export const hero_title = (inputs = {}, options = {}) => {
      const locale = options.locale ?? getLocale();
    
      if (locale === "en") return en.hero_title(inputs);
      if (locale === "fr") return fr.hero_title(inputs);
      // ...one branch per locale
    };
    

    A French visitor downloads the English, Spanish, German... versions of every string on the page. With 2 locales, half your translations are dead weight. With 10 locales, 90% of the translated content shipped to the page is never displayed. Paraglide has no dynamic mode to fix this, and loading one function per message lazily would mean thousands of requests.

    The second cost is getLocale(). With no provider, every m.key() call resolves the locale again (cookie, storage, URL). A page with 200 strings resolves it 200 times per render.

    More details in Is Intlayer lighter than Paraglide?.

    Made for Svelte, Less So for React

    Paraglide is a simple tool: it generates plain JavaScript into your codebase, so the same output works in Svelte, Vue, vanilla JS or React. In a Svelte template, {m.hero_title()} is idiomatic, and the Svelte + Vite benchmark is where its tree shaking works best.

    • In React, a function call per string (<>{m.hero_title()}</>) can be considered an anti-pattern
    • React doesn't know the result depends on the locale, so nothing re-renders when it changes. Paraglide's setLocale() reloads the whole page by default.
    • The call runs again on every render of every component, locale resolution included.
    • Rich content (a link or a <strong> inside a sentence) doesn't fit in a string-returning function.

    Intlayer also works across frameworks, but with a dedicated integration for each framework and meta-framework, built for how each one renders: React context and Server Components, Vue refs, Svelte stores, Solid and Angular signals, plus Next.js, Nuxt, SvelteKit, TanStack Start, React Router, Astro and server frameworks such as Express or Hono.

    What About General Translation?

    GT is a young framework, and its business is AI translation served from its CDN. We took apart a production app built on gt-react (T3 Code) and found:

    • a 38 KB gzipped runtime, about twice react-i18next;
    • one catalog per locale for the whole app, so 63% of what a French user loads is for screens they haven't opened;
    • every string shipped twice: the English source in the code, the translation in the catalog;
    • strings keyed by a hash of the English text, so fixing a typo breaks the key.

    • T3 Code

    If you picked Paraglide for its bundle size, GT goes the other way.

    Why Intlayer

    Intlayer also imports dictionaries where they are used, so other pages don't leak either. With importMode: "dynamic", it also loads only the current locale, which Paraglide can't do. A provider reads the locale once per render instead of once per string, and the compiler lets you write plain text in your JSX and extracts it at build time.

    TanStack Start, 10 pages, gzipped:

    SetupPage JS avgAbove baseLocale leakOther-page leak
    Base (no i18n)111.0 KB-0.0%0.0%
    paraglide (any strategy)125.1 KB+14.1 KB49.7%0.0%
    intlayer (importMode: dynamic)118.6 KB+7.6 KB0.0%0.0%

    Metric

    Dynamic JSON loading

    Lazy-loads translations at runtime

    Scoped JSON (namespacing)

    Per-page translation namespaces

    What is this metric?

    The total gzip-compressed size of the internationalisation library bundle. It only includes the provider and content retrieval logic after tree-shaking and minification.

    Why is it important?

    A smaller library size reduces the initial JavaScript payload, leading to faster download and execution times on the client.

    View as

    Full data: TanStack Start benchmark, Next.js benchmark.

    Feature Comparison

    FeatureIntlayerParaglide JSGeneral Translation (gt-react, gt-next)
    Maintained byIntlayer team (Apache-2.0)GT team since November 2026 (MIT)GT, a company selling AI translation (SDK under MIT)
    Translations near components✅ Co-located content files, or plain text with the compiler❌ One JSON file per locale⚠️ Source text inline, translations in a central catalog
    TypeScript integration✅ Auto-generated types✅ Typed message functions⚠️ No keys to type (hashed source text)
    Missing translation detection✅ Type errors, build warnings, npx intlayer test in CI⚠️ Falls back to the base locale⚠️ Falls back to the source text
    Rich content (JSX, Markdown)✅ Direct support⚠️ Strings only✅ JSX inside <T>
    Pluralization✅ plural(), enu()✅ Variants✅ <Plural>, <Branch>
    Localised routing✅ Built-in, localised paths (Next.js, Vite)✅ urlPatterns + router rewrite✅ Via gt-next middleware
    Per-page content split✅ Per dictionary✅ Per message (depends on the bundler)❌ One catalog per locale for the whole app
    Load only the current locale✅ importMode: "dynamic" or "fetch"❌ Every locale inside every message⚠️ One catalog, plus the English source in the code
    Locale resolution✅ Once, from a provider⚠️ On every message call✅ Once, from a provider
    Runtime size (gzip)~5 KB1.8 KB, plus the runtime generated into your app~38 KB
    AI translation✅ Free, with your own API key or a local model (Ollama, LM Studio)⚠️ Not built-in, docs point to GT's service⚠️ GT's hosted service, paid
    Visual editor / CMS✅ Local editor + optional CMS⚠️ inlang apps✅ GT dashboard (hosted)
    VS Code extension✅ Go to definition, extraction, inlay hints, key rename⚠️ Sherlock (inlang), through a plugin❌ None found
    LSP (Zed, Neovim, other editors)✅ @intlayer/lsp❌ No❌ No
    FrameworksReact, Next.js, Vue, Svelte, Angular, Solid, Astro, Lit, backends and moreAny JS frameworkReact, Next.js, React Native, TanStack Start, Vue
    Runtime sizes come from the TanStack Start benchmark and the T3 Code analysis. See also the VS Code extension, the LSP and the AI provider configuration.

    API Mapping

    Paraglide JSIntlayer
    project.inlang/settings.jsonintlayer.config.ts
    messages/{locale}.jsonPlain text in your components (compiler) or .content.ts
    m.hero_title()Ship faster in JSX, or content.title
    m.greeting({ name })Hello {name} in JSX, or content.greeting({ name })
    getLocale() / setLocale()useLocale() from react-intlayer
    localizeHref()getLocalizedUrl() from intlayer
    paraglideMiddleware in server.tsBuilt into the intlayer() Vite plugin
    Router rewrite (deLocalizeUrl){-$locale} route segment
    urlPatterns (localised pathnames)routing.rewrite in intlayer.config.ts
    paraglideVitePluginintlayer() from vite-intlayer

    Migrate Step by Step

    The examples below use TanStack Start with React. The same steps apply to Next.js, Svelte, Vue or Astro with the matching Intlayer package.

    1. Install Intlayer

      bash
      npx intlayer init --interactive
      

      The command detects your framework, installs intlayer, react-intlayer and vite-intlayer, and creates intlayer.config.ts. Select Compiler when asked.

    2. Port your locales and enable the compiler

      Copy the locales from project.inlang/settings.json:

      intlayer.config.ts
      import { Locales, type IntlayerConfig } from "intlayer";
      
      const config: IntlayerConfig = {
        internationalization: {
          locales: [Locales.ENGLISH, Locales.FRENCH, Locales.SPANISH],
          defaultLocale: Locales.ENGLISH,
        },
        routing: {
          mode: "prefix-no-default", // /about, /fr/about
        },
        dictionary: {
          importMode: "dynamic", // load only the current locale
        },
        compiler: {
          enabled: true,
          // Write the extracted content next to each component
          output: ({ fileName, extension }) => `./${fileName}${extension}`,
        },
      };
      
      export default config;
      
    3. Swap the Vite plugin and remove the Paraglide middleware

      vite.config.ts
      import { tanstackStart } from "@tanstack/react-start/plugin/vite";
      import viteReact from "@vitejs/plugin-react";
      import { defineConfig } from "vite";
      import { intlayer } from "vite-intlayer";
      
      export default defineConfig({
        plugins: [
          // paraglideVitePlugin({ project: "./project.inlang", outdir: "./src/paraglide" }),
          intlayer(),
          tanstackStart({
            router: {
              routeFileIgnorePattern:
                ".content.(ts|tsx|js|mjs|cjs|jsx|json|jsonc|json5|md|mdx|yaml|yml)$",
            },
          }),
          viteReact(),
        ],
      });
      

      The intlayer() plugin includes the locale detection and redirection that paraglideMiddleware did, so you can delete src/server.ts (or the middleware call in it) and the rewrite block in src/router.tsx.

    4. Move your routes under {-$locale}

      Paraglide strips the locale prefix with a router rewrite. Intlayer uses an optional route segment instead, so TanStack Router stays aware of the locale and typed links keep working:

      bash
      src/routes/
      ├── __root.tsx
      └── {-$locale}/
          ├── route.tsx      # Validates the prefix, renders <IntlayerProvider>
          ├── index.tsx      # / and /fr
          └── about.tsx      # /about and /fr/about
      

      The TanStack Start guide has the full route.tsx, root layout, localised link and locale switcher.

    5. Put your strings back into your components

      Replace each m.key() call with the English text it returns:

      src/components/Hero.tsx
      // Before
      import { m } from "../paraglide/messages.js";
      
      export const Hero = ({ name }: { name: string }) => (
        <section>
          <h1>{m.hero_title()}</h1>
          <p>{m.hero_greeting({ name })}</p>
          <input placeholder={m.hero_search_placeholder()} />
        </section>
      );
      
      src/components/Hero.tsx
      // After
      export const Hero = ({ name }: { name: string }) => (
        <section>
          <h1>Ship your app in every language</h1>
          <p>Hello {name}, welcome back</p>
          <input placeholder="Search the docs" />
        </section>
      );
      

      The component no longer imports messages or references keys. On a large codebase, give this prompt to your coding agent:

      text
      Remove Paraglide JS from this project. For every call to a message function
      from "paraglide/messages" (m.key() or m.key({ ... })), replace it with the
      English text from messages/en.json. Write it inline in the JSX, or as a string
      literal in attributes. Turn {param} placeholders into JSX expressions
      ({param}) or template literals. Remove the now-unused imports.
      Don't touch messages/*.json yet.
      
    6. Let the compiler extract the content

      Run the dev server or a build. The compiler detects user-facing text in your components (JSX text, title, placeholder, alt, aria-label...), writes a content file next to each component, and swaps the text for a useIntlayer() call in the build output. Your source files stay as you wrote them.

      src/components/Hero.content.json
      {
        "key": "hero",
        "content": {
          "shipYourAppInEveryLanguage": {
            "nodeType": "translation",
            "translation": { "en": "Ship your app in every language" }
          }
        }
      }
      

      Keep a string out of extraction (brand names, IDs) with an intlayer-ignore-next-line comment. See the compiler documentation.

    7. Bring back your existing translations

      The extracted files only hold English at this point. Your French, Spanish... translations are still in messages/*.json. Copy them over before deleting anything:

      text
      For each *.content.json file generated by the Intlayer compiler, find the
      English value in messages/en.json, take the matching key from
      messages/{locale}.json, and add it under "translation" for each locale.
      Convert {param} placeholders to {{param}}.
      

      Then check that nothing is missing, and translate the rest with your own API key or a local model:

      bash
      npx intlayer test   # list missing translations
      npx intlayer fill   # translate what's missing
      
    8. Remove Paraglide

      Delete project.inlang/, messages/, src/paraglide/ and the @inlang/paraglide-js dependency. Then open your bundle visualizer: each page should now carry only its own content, in one locale.

    Prefer Explicit Content Files?

    The compiler is optional. If you'd rather keep content in files you write yourself, declare it next to the component:

    src/components/Hero.content.ts
    import { insert, t, type Dictionary } from "intlayer";
    
    export default {
      key: "hero",
      content: {
        title: t({
          "en-GB": "Ship your app in every language",
          en: "Ship your app in every language",
          fr: "Publiez votre app dans toutes les langues",
        }),
        greeting: insert(
          t({
            "en-GB": "Hello {{name}}, welcome back",
            en: "Hello {{name}}, welcome back",
            fr: "Bonjour {{name}}, bon retour",
          })
        ),
      },
    } satisfies Dictionary;
    
    src/components/Hero.tsx
    import { useIntlayer } from "react-intlayer";
    
    export const Hero = ({ name }: { name: string }) => {
      const { title, greeting } = useIntlayer("hero");
    
      return (
        <section>
          <h1>{title}</h1>
          <p>{greeting({ name })}</p>
        </section>
      );
    };
    

    To convert existing components into content files in one pass, run npx intlayer extract. Read Compiler vs. Declarative i18n to choose between the two.

    FAQ

    Yes. General Translation says Paraglide stays free and MIT-licensed, and that it will keep fixing bugs and security issues. New work goes toward GT's translation CLI, dashboard and inference.

    Partly. The syncJSON plugin with format: "icu" reads messages/{locale}.json as Intlayer dictionaries, and simple {param} messages work as is. Paraglide's plural variants have a different shape and need to be rewritten with plural(). You would also keep one big dictionary, which loses the per-page split.

    No, as long as you keep the same routing mode. prefix-no-default gives /about and /fr/about, like Paraglide's default url strategy patterns. Localised pathnames (/fr/a-propos) go in routing.rewrite, see Custom URL Rewrites.

    Yes. Paraglide and Intlayer don't share anything at runtime, so both can run side by side while you move components over. Remove Paraglide once the last m. import is gone.

    Further Reading

    Comments

    No comments yet. Be the first to share your thoughts.

    Related Posts

    Last Posts