Neki is currently in Platform Preview. Platform Preview features are “Beta Features” under the PlanetScale Terms of Service or your applicable agreement with PlanetScale. Accordingly, Neki is subject to the limitations and disclaimers applicable to Beta Features and is not covered by any service level agreement.
Neki is the best way to scale a highly-available Postgres database. It provides sharding, zero-downtime operations, online DDL, replication workflows, and sophisticated cluster management capabilities, all using real Postgres.Neki abstracts all of this capability behind a single connection string that speaks the Postgres wire protocol.
It accomplishes this by placing a sophisticated proxy (router) between clients and the Postgres nodes.
This router parses, plans, and coordinates all of the Postgres traffic, routing it to the correct nodes in an extremely efficient way.All of these capabilities come with the other PlanetScale features like Insights, anomalies, and schema recommendations.
This makes it a perfect solution for anything from a massive database storing hundreds of terabytes across many shards, all the way down to small, unsharded Postgres databases with a handful of gigabytes.You do not have to shard to use Neki. A new database starts as an unsharded cluster. You still get all the benefits of zero-downtime upgrades, cluster management, connection pooling and more.
Whether you later shard depends on your traffic, access patterns, and data — see When to shard.
Architecture
The components of a Neki deployment and how they fit together.
When to shard
Whether sharding is the right answer to the limits you’re hitting.
Quickstart
Create your first Neki database, connect, and insert data.
Neki vs PlanetScale Postgres
The upgrade from a single primary, and the habits that change.
Neki is currently available through the PlanetScale Platform Preview. An organization administrator can select Join the Platform Preview from the organization dashboard or open Organization settings > Platform Preview and accept the preview terms. Neki then appears as a database engine.
Neki is built by PlanetScale, the maintainers of Vitess.
Vitess already runs some of the largest services on the internet, including Slack, Square, and Cursor.Neki is not a Vitess port.
It is built from scratch to specifically solve the scalability and operational challenges of Postgres.
{"docsConfig":{"theme":"aspen","$schema":"https://mintlify.com/docs.json","name":"PlanetScale","description":"PlanetScale is a relational database platform for Vitess, Neki, and Postgres that gives you scale, performance, and reliability without sacrificing developer experience.","colors":{"primary":"#0e73cc","light":"#47b7f8","dark":"#f15817"},"logo":{"light":"https://mintcdn.com/planetscale-2/xUilVHToUFALai8a/logo/light.png?fit=max\u0026auto=format\u0026n=xUilVHToUFALai8a\u0026q=85\u0026s=cccd3c9fc813c01b899ab7af15a115b1","dark":"https://mintcdn.com/planetscale-2/xUilVHToUFALai8a/logo/dark.png?fit=max\u0026auto=format\u0026n=xUilVHToUFALai8a\u0026q=85\u0026s=4153888dc0ef54ddc3464738a2d7ee6e","href":"https://planetscale.com"},"favicon":"https://mintcdn.com/planetscale-2/DJh9Bv1aUZHTVDnK/favicon.svg?fit=max\u0026auto=format\u0026n=DJh9Bv1aUZHTVDnK\u0026q=85\u0026s=cc6ec9d8d0deb3450719bb4b5b6df73a","background":{"color":{"light":"#fafafa","dark":"#111111"}},"navbar":{"links":[{"href":"https://auth.planetscale.com/sign-in","label":"Log in"},{"href":"https://auth.planetscale.com/sign-up","label":"Get started"}],"primary":{"type":"button","label":"Get in touch","href":"https://planetscale.com/contact"}},"footer":{"socials":{"x":"https://twitter.com/planetscale","github":"https://github.com/planetscale","linkedin":"https://www.linkedin.com/company/planetscale","youtube":"https://www.youtube.com/c/PlanetScale","discord":"https://pscale.link/community","facebook":"https://www.facebook.com/planetscaledata"}},"seo":{"metatags":{"canonical":"https://planetscale.com/docs"}},"fonts":{"heading":{"family":"Inter"},"body":{"family":"Inter"}},"integrations":{"segment":{"key":"9Ujczlrndco2w8fcFAakL0FT4bsJCCh3"}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"styling":{"latex":false},"navigation":{"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://planetscale.com/blog"},{"anchor":"Contact Us","icon":"headset","href":"https://planetscale.com/contact"},{"anchor":"Status","icon":"signal","href":"https://www.planetscalestatus.com/"},{"anchor":"Benchmarks","icon":"chart-line","href":"https://planetscale.com/benchmarks"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"planetscale-2","hasAudioNarration":false,"actualSubdomain":"planetscale-2","customDomains":["planetscale.com"],"gitSource":{"type":"github","owner":"planetscale","repo":"www","deployBranch":"main","contentDirectory":"content/mintlify/docs","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6ae4bbcf6d3c0060a25eeaab","collectionId":"049ef4be-45cb-4471-af55-3e8b42112ffe","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ae4bbcf6d3c0060a25eeaab"},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"CONTEXTUAL_FEEDBACK":{"status":"ENABLED"},"CODE_SNIPPET_FEEDBACK":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6ae4cefc4c4a3f4f5e4b3a5b","clientVersion":"0.0.4043","searchFilterCounts":[{"language":"default","tag":"Platform","count":288},{"language":"default","tag":"API Reference","count":268},{"language":"default","tag":"Vitess","count":184},{"language":"default","tag":"Postgres","count":108},{"language":"default","tag":"General API endpoints","count":97},{"language":"default","tag":"Neki","count":58},{"language":"default","tag":"Guides","count":58},{"language":"default","tag":"Vitess API endpoints","count":56},{"language":"default","tag":"Postgres API endpoints","count":51},{"language":"default","tag":"Neki API endpoints","count":50}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableAskAiSearchBar":true,"deflection":{"enabled":true,"type":"link","url":"https://planetscale.com/contact?initial=support"}},"basePath":"/docs","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"#content-container{column-gap:2rem}.nav-tabs{column-gap:.5em}.nav-tabs-item{padding:0 8px}.eyebrow,.light #navigation-items .text-gray-700,.nav-tabs a{color:#616161}#navigation-items .text-primary,#topbar-cta-button .text-white,#topbar-cta-button svg,.nav-tabs a.text-primary{color:#1a1a1a}.nav-tabs a.text-primary .bg-primary{background-color:#1a1a1a;left:0}.dark .nav-tabs a[href='/docs/vitess'i].text-primary,.nav-tabs a[href='/docs/vitess'i].text-primary{color:#f15817}.dark .nav-tabs a[href='/docs/vitess'i].text-primary .bg-primary,.nav-tabs a[href='/docs/vitess'i].text-primary .bg-primary{background-color:#f15817}.nav-tabs a[href='/docs/postgres'i].text-primary{color:#0e73cc}.nav-tabs a[href='/docs/postgres'i].text-primary .bg-primary{background-color:#0e73cc}.nav-tabs a[href='/docs/neki'i].text-primary{color:#8f7200}.nav-tabs a[href='/docs/neki'i].text-primary .bg-primary{background-color:#8f7200}.dark .nav-tabs a{color:#a1a1a1}.dark #navigation-items .text-primary,.dark .nav-tabs a.text-primary{color:#fafafa}.dark .nav-tabs a.text-primary .bg-primary{background-color:#fafafa}.dark .nav-tabs a[href='/docs/postgres'i].text-primary{color:#47b7f8}.dark .nav-tabs a[href='/docs/postgres'i].text-primary .bg-primary{background-color:#47b7f8}.dark .nav-tabs a[href='/docs/neki'i].text-primary{color:#fbca00}.dark .nav-tabs a[href='/docs/neki'i].text-primary .bg-primary{background-color:#fbca00}.prose:is(.dark *){color:#c1c1c1}.prose :where(a):not(:where([class~='not-prose'], [class~='not-prose'] *)){color:#0e73cc;font-weight:500}.dark .prose :where(a):not(:where(.not-prose, .not-prose *)){color:#47b7f8}.dark .eyebrow{color:#a1a1a1}@media (min-width:1024px){#content-container{padding-top:2rem;padding-right:2rem;padding-left:2.5rem}}#topbar-cta-button a>span{background-color:#fbca00}.group:hover span{opacity:1!important}.bg-primary\\/10{background-color:rgba(129,129,129,.1)}.dark .bg-primary\\/10{background-color:rgba(255,255,255,.1)}body[data-current-path^='/vitess'] svg.bg-primary{background-color:#f15817}body[data-current-path^='/vitess'] .border-primary{border-color:#f15817}body[data-current-path^='/vitess'] #table-of-contents-content .text-primary,body[data-current-path^='/vitess'] .eyebrow{color:#f15817}body[data-current-path^='/vitess'] .card-group a:hover{border-color:#f15817!important}body[data-current-path^='/postgres'] .eyebrow{color:#0e73cc}.dark body[data-current-path^='/postgres'] .eyebrow{color:#47b7f8}body[data-current-path^='/neki'] svg.bg-primary{background-color:#8f7200}body[data-current-path^='/neki'] [data-component-part=card-icon]{background-color:#fbca00}body[data-current-path^='/neki'] [data-component-part=card-icon] svg.bg-primary{background-color:#1a1a1a;transform:scale(.7);transform-origin:center}body[data-current-path^='/neki'] .border-primary{border-color:#8f7200}body[data-current-path^='/neki'] #table-of-contents-content .text-primary{color:#1a1a1a;background-color:transparent;border-color:#fbca00}body[data-current-path^='/neki'] .eyebrow{display:inline-flex;align-items:center;width:fit-content;height:auto;min-height:1.25rem;padding:0 .375rem;color:#1a1a1a;background-color:#fbca00}body[data-current-path^='/neki'] .eyebrow:empty,body[data-current-path^='/neki'] .eyebrow[data-empty]{display:none}.dark body[data-current-path^='/neki'] .card-group .card:hover,body[data-current-path^='/neki'] .card-group .card:hover{--primary:251 202 0;--primary-light:251 202 0;border-color:#fbca00!important}.dark body[data-current-path^='/neki'] [data-component-part=card-icon],.dark body[data-current-path^='/neki'] svg.bg-primary{background-color:#fbca00}.dark body[data-current-path^='/neki'] [data-component-part=card-icon] svg.bg-primary{background-color:#1a1a1a}.dark body[data-current-path^='/neki'] .border-primary{border-color:#fbca00}.dark body[data-current-path^='/neki'] #table-of-contents-content .text-primary{color:#fafafa;background-color:transparent;border-color:#fbca00}.dark body[data-current-path^='/neki'] .eyebrow{color:#1a1a1a;background-color:#fbca00}footer div:last-child{display:none}#header,#pagination a,[data-component-part=card-content-container],[data-component-part=frame-caption]{text-wrap:balance}.step:last-of-type [data-component-part=step-line]{opacity:0}"}],"page":{"pagePath":"neki","slug":"/neki","pageMetadata":{"title":"Neki","description":"Horizontal sharding for Postgres","og:image":"images/og/neki.png","href":"/neki"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Horizontal sharding for Postgres\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,p:`p`,strong:`strong`,..._provideComponents(),...props.components},{Card,CardGroup,Heading,Note}=_components;if(!Card)_missingMdxReference(`Card`,true);if(!CardGroup)_missingMdxReference(`CardGroup`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);return _jsxs(_Fragment,{children:[_jsx(Note,{children:_jsx(_components.p,{children:`Neki is currently in Platform Preview. Platform Preview features are “Beta Features” under the PlanetScale Terms of Service or your applicable agreement with PlanetScale. Accordingly, Neki is subject to the limitations and disclaimers applicable to Beta Features and is not covered by any service level agreement.`})}),`\n`,_jsx(_components.p,{children:`Neki is the best way to scale a highly-available Postgres database. It provides sharding, zero-downtime operations, online DDL, replication workflows, and sophisticated cluster management capabilities, all using real Postgres.`}),`\n`,_jsx(_components.p,{children:`Neki abstracts all of this capability behind a single connection string that speaks the Postgres wire protocol.\nIt accomplishes this by placing a sophisticated proxy (router) between clients and the Postgres nodes.\nThis router parses, plans, and coordinates all of the Postgres traffic, routing it to the correct nodes in an extremely efficient way.`}),`\n`,_jsxs(_components.p,{children:[`All of these capabilities come with the other PlanetScale features like `,_jsx(_components.a,{href:`/neki/monitoring/query-insights`,children:`Insights`}),`, `,_jsx(_components.a,{href:`/neki/monitoring/anomalies`,children:`anomalies`}),`, and `,_jsx(_components.a,{href:`/neki/monitoring/schema-recommendations`,children:`schema recommendations`}),`.\nThis makes it a perfect solution for anything from a massive database storing hundreds of terabytes across many shards, all the way down to small, unsharded Postgres databases with a handful of gigabytes.`]}),`\n`,_jsxs(_components.p,{children:[`You do not have to shard to use Neki. A new database starts as an unsharded cluster. You still get all the benefits of zero-downtime upgrades, cluster management, connection pooling and more.\nWhether you later shard depends on your traffic, access patterns, and data — see `,_jsx(_components.a,{href:`/neki/when-to-shard`,children:`When to shard`}),`.`]}),`\n`,_jsxs(CardGroup,{cols:2,children:[_jsx(Card,{title:`Architecture`,href:`/neki/overview`,icon:`database`,children:_jsx(_components.p,{children:`The components of a Neki deployment and how they fit together.`})}),_jsx(Card,{title:`When to shard`,href:`/neki/when-to-shard`,icon:`scale-balanced`,children:_jsx(_components.p,{children:`Whether sharding is the right answer to the limits you’re hitting.`})}),_jsx(Card,{title:`Quickstart`,href:`/neki/tutorials/planetscale-quick-start-guide`,icon:`rocket-launch`,children:_jsx(_components.p,{children:`Create your first Neki database, connect, and insert data.`})}),_jsx(Card,{title:`Neki vs PlanetScale Postgres`,href:`/neki/coming-from-postgres`,icon:`table-columns`,children:_jsx(_components.p,{children:`The upgrade from a single primary, and the habits that change.`})})]}),`\n`,_jsx(Heading,{level:`2`,id:`availability-and-access`,children:`Availability and access`}),`\n`,_jsxs(_components.p,{children:[`Neki is currently available through the PlanetScale Platform Preview. An organization administrator can select `,_jsx(_components.strong,{children:`Join the Platform Preview`}),` from the organization dashboard or open `,_jsx(_components.strong,{children:`Organization settings`}),` > `,_jsx(_components.strong,{children:`Platform Preview`}),` and accept the preview terms. Neki then appears as a database engine.`]}),`\n`,_jsx(Heading,{level:`2`,id:`from-the-maintainers-of-vitess`,children:`From the maintainers of Vitess`}),`\n`,_jsxs(_components.p,{children:[`Neki is built by PlanetScale, the maintainers of `,_jsx(_components.a,{href:`/vitess`,children:`Vitess`}),`.\nVitess already runs some of the largest services on the internet, including Slack, Square, and Cursor.`]}),`\n`,_jsx(_components.p,{children:`Neki is not a Vitess port.\nIt is built from scratch to specifically solve the scalability and operational challenges of Postgres.`}),`\n`,_jsx(Heading,{level:`2`,id:`need-help`,children:`Need help?`}),`\n`,_jsxs(_components.p,{children:[`Get help from `,_jsx(_components.a,{href:`https://planetscale.com/contact?initial=support`,children:`the PlanetScale Support team`}),`, or join our\\xA0`,_jsx(_components.a,{href:`https://pscale.link/community`,children:`Discord community`}),` to see how others are using PlanetScale.`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Neki","description":"Horizontal sharding for Postgres","og:image":"images/og/neki.png","href":"/neki"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Availability and access","slug":"availability-and-access","depth":2,"children":[]},{"title":"From the maintainers of Vitess","slug":"from-the-maintainers-of-vitess","depth":2,"children":[]},{"title":"Need help?","slug":"need-help","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/docs/_mintlify/custom/planetscale-2/b155242ec3c4945e/custom.js"],"subdomain":"planetscale-2","siteName":"PlanetScale","title":"Neki - PlanetScale","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-09-10T15:31:46.131Z","originalFileLocation":"neki.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Horizontal sharding for Postgres\">\u003cmeta data-mint-head name=\"application-name\" content=\"PlanetScale\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Neki - PlanetScale\">\u003cmeta data-mint-head property=\"og:description\" content=\"Horizontal sharding for Postgres\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"PlanetScale\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://planetscale.com/docs/neki\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://planetscale-2.mintlify.app/images/og/neki.png\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Neki - PlanetScale\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Horizontal sharding for Postgres\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://planetscale-2.mintlify.app/images/og/neki.png\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/docs/mintlify-assets/_mintlify/favicons/planetscale-2/_bFyi8IG4CeLblEd/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"PlanetScale\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#0e73cc\">\u003clink data-mint-head rel=\"canonical\" href=\"https://planetscale.com/docs/neki\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/neki.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://planetscale.com/#organization\",\"name\":\"PlanetScale\",\"url\":\"https://planetscale.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/planetscale-2/xUilVHToUFALai8a/logo/light.png?fit=max\u0026auto=format\u0026n=xUilVHToUFALai8a\u0026q=85\u0026s=cccd3c9fc813c01b899ab7af15a115b1\"}},{\"@type\":\"WebSite\",\"@id\":\"https://planetscale.com/docs#website\",\"name\":\"PlanetScale\",\"url\":\"https://planetscale.com/docs\",\"publisher\":{\"@id\":\"https://planetscale.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://planetscale.com/docs/neki#webpage\",\"url\":\"https://planetscale.com/docs/neki\",\"name\":\"Neki\",\"description\":\"Horizontal sharding for Postgres\",\"dateModified\":\"2026-09-10T15:31:46.131Z\",\"isPartOf\":{\"@id\":\"https://planetscale.com/docs#website\"},\"breadcrumb\":{\"@id\":\"https://planetscale.com/docs/neki#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://planetscale.com/docs/neki#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"PlanetScale\",\"item\":\"https://planetscale.com/docs\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Neki\",\"item\":\"https://planetscale.com/docs/neki\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://planetscale.com/docs/neki#article\",\"headline\":\"Neki\",\"name\":\"Neki\",\"description\":\"Horizontal sharding for Postgres\",\"url\":\"https://planetscale.com/docs/neki\",\"mainEntityOfPage\":{\"@id\":\"https://planetscale.com/docs/neki#webpage\"},\"image\":\"https://planetscale.com/docs/images/og/neki.png\",\"dateModified\":\"2026-09-10T15:31:46.131Z\",\"publisher\":{\"@id\":\"https://planetscale.com/#organization\"},\"isPartOf\":{\"@id\":\"https://planetscale.com/docs#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"PlanetScale\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"PlanetScale","nav":{"global":{"anchors":[{"anchor":"Blog","icon":"newspaper","href":"https://planetscale.com/blog"},{"anchor":"Contact Us","icon":"headset","href":"https://planetscale.com/contact"},{"anchor":"Status","icon":"signal","href":"https://www.planetscalestatus.com/"},{"anchor":"Benchmarks","icon":"chart-line","href":"https://planetscale.com/benchmarks"}]},"tabs":[{"tab":"Platform","pages":[{"title":"Platform","href":""}]},{"tab":"Vitess","pages":[{"title":"Vitess","href":"/vitess"}]},{"tab":"Neki","groups":[{"group":" ","pages":[{"title":"Neki","href":"/neki"}]},{"group":"Architecture","pages":[{"group":"Foundations","pages":[{"title":"Overview","description":"The components of a Neki deployment and how they fit together","href":"/neki/overview"},{"title":"When to shard","href":"/neki/when-to-shard"},{"title":"Neki vs PlanetScale Postgres","href":"/neki/coming-from-postgres"},{"title":"Neki vs Vitess","href":"/neki/vitess-and-postgres"}]},{"group":"Core concepts","pages":[{"title":"Data topology","href":"/neki/data-topology"},{"title":"Query planning","href":"/neki/query-planning"},{"title":"Shard targeting and fanout","href":"/neki/shard-targeting-fanout"},{"title":"Transactions","href":"/neki/transactions"},{"title":"Reference tables and GSIs","href":"/neki/reference-tables-and-gsis"},{"title":"Replicator workflows","sidebarTitle":"Replicator","href":"/neki/replication"}]},{"group":"Workflows","pages":[{"title":"Data migration","href":"/neki/data-migration"},{"title":"Schema changes","href":"/neki/schema-changes"}]},{"group":"Reference","pages":[{"title":"Platform preview limitations","href":"/neki/platform-preview-limitations"},{"title":"Neki terminology","sidebarTitle":"Terminology","href":"/neki/terminology"},{"title":"Neki error codes","sidebarTitle":"Error codes","href":"/neki/error-codes"},{"title":"Error hints and details","sidebarTitle":"Hints and details","href":"/neki/error-hints-and-details"},{"title":"EXPLAIN output reference","sidebarTitle":"EXPLAIN output","href":"/neki/explain-reference"},{"title":"Example schema","href":"/neki/example-schema"}]}]},{"group":"Pricing","pages":[{"title":"Neki pricing","sidebarTitle":"Pricing","href":"/neki/pricing"}]},{"group":"Platform","pages":[{"group":"Getting started","pages":[{"title":"Neki database dashboard","sidebarTitle":"Dashboard overview","href":"/neki/neki-dashboard"},{"title":"Neki quickstart","href":"/neki/tutorials/planetscale-quick-start-guide"},{"title":"Neki sharding quickstart","sidebarTitle":"Sharding quickstart","href":"/neki/tutorials/sharding-quick-start-guide"},{"title":"Neki best practices","sidebarTitle":"Best practices","href":"/neki/best-practices"}]},{"group":"Connecting","pages":[{"title":"Connect to Neki","sidebarTitle":"Overview","href":"/neki/connecting"},{"title":"Roles and credentials","href":"/neki/connecting/roles"},{"title":"PlanetScale Terraform provider","sidebarTitle":"Terraform provider","href":"/terraform"},{"group":"Private connections","pages":[{"title":"Connect privately with AWS PrivateLink","sidebarTitle":"AWS PrivateLink","href":"/neki/connecting/private-connections/aws-privatelink"},{"title":"Connect privately with GCP Private Service Connect","sidebarTitle":"GCP Private Service Connect","href":"/neki/connecting/private-connections/gcp-private-service-connect"}]},{"title":"Web console","href":"/neki/web-console"}]},{"group":"Configuration","pages":[{"title":"Cluster sizing","href":"/neki/cluster-configuration/cluster-sizing"},{"title":"Cluster configuration","href":"/neki/cluster-configuration"},{"title":"Configure Neki maintenance windows","sidebarTitle":"Maintenance windows","href":"/neki/cluster-configuration/maintenance-windows"},{"title":"Configuration parameters","sidebarTitle":"Parameters","href":"/neki/cluster-configuration/parameters"},{"title":"Database replicas","sidebarTitle":"Replicas","href":"/neki/replicas"},{"title":"Read-only replicas","sidebarTitle":"Read-only replicas","href":"/neki/read-only-replicas"}]},{"title":"Postgres extensions","sidebarTitle":"Extensions","href":"/neki/extensions"},{"group":"Migrate to Neki","pages":[{"title":"Import a Postgres database","sidebarTitle":"Import Postgres","href":"/neki/imports/postgres"},{"title":"Troubleshoot a Neki migration","sidebarTitle":"Migration troubleshooting","href":"/neki/imports/troubleshooting"}]},{"group":"Branching","pages":[{"title":"Branching","href":"/neki/branching"},{"title":"Development environments","href":"/neki/development-environments"}]},{"group":"Monitoring","pages":[{"title":"Monitor a Neki database","sidebarTitle":"Monitoring overview","href":"/neki/monitoring"},{"title":"Query Insights","href":"/neki/monitoring/query-insights"},{"title":"Anomalies","href":"/neki/monitoring/anomalies"},{"title":"Schema recommendations","href":"/neki/monitoring/schema-recommendations"},{"title":"Metrics","href":"/neki/monitoring/metrics"},{"title":"Logs","href":"/neki/monitoring/logs"},{"title":"Inspect live Neki connections","sidebarTitle":"Connections","href":"/neki/monitoring/connections"},{"title":"Prometheus metrics for PlanetScale Neki","sidebarTitle":"Prometheus metrics reference","href":"/neki/monitoring/prometheus-metrics-neki"}]},{"title":"Back up and restore","sidebarTitle":"Backups","href":"/neki/backups"}]},{"group":"Guides","pages":[{"group":"Frameworks and ORMs","pages":[{"title":"Connect a Node.js application to Neki","sidebarTitle":"Node.js","href":"/neki/guides/node"},{"title":"Connect Drizzle to Neki","sidebarTitle":"Drizzle","href":"/neki/guides/drizzle"},{"title":"Connect Kysely to Neki","sidebarTitle":"Kysely","href":"/neki/guides/kysely"},{"title":"Connect Prisma to Neki","sidebarTitle":"Prisma","href":"/neki/guides/prisma"},{"title":"Connect a Ruby on Rails application to Neki","sidebarTitle":"Ruby on Rails","href":"/neki/guides/rails"},{"title":"Connect a Django application to Neki","sidebarTitle":"Django","href":"/neki/guides/django"},{"title":"Connect a Laravel application to Neki","sidebarTitle":"Laravel","href":"/neki/guides/laravel"},{"title":"Connect a Bun application to Neki","sidebarTitle":"Bun","href":"/neki/guides/bun"},{"title":"Connect Cloudflare Workers to Neki","sidebarTitle":"Cloudflare Workers","href":"/neki/guides/cloudflare-workers"}]}]}]},{"tab":"Postgres","pages":[{"title":"Postgres","href":"/postgres"}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/api/reference/getting-started-with-planetscale-api"}]},{"tab":"CLI Reference","pages":[{"title":"CLI Reference","href":"/cli"}]}]},"basePath":"","title":"Neki - PlanetScale","buildId":"dpl_4RHMRqtvdHvKgaEfTTjFqjzja3B6","deploymentId":"dpl_4RHMRqtvdHvKgaEfTTjFqjzja3B6","dynamics":[],"chunks":[]}