Type-safe search params state management for Next.js
Next.js has APIs to read and update search params (the /?foo=bar part of the URL), but they lack type-safety for consistent keys and proper parsing/serializing of JS data types. I found myself repeatedly building the same custom hook to get a React.useState-like approach. In 2021, I published it to NPM and then forgot about it. Since then, the `nuqs` package has gained popularity and is now used by companies like Vercel, Auth.js, Gitbook, and Midday.ai, with 200K weekly downloads. It's been fun building this as a side project and automating as much as possible to ensure a…
Type-safe search params state management for Next.js launched on August 5, 2024 with 10 votes, #1,497 of 5,471 launches that month and more than 75% of that year's launches. The site was still online in September 2026, 2 years on.
In plain words
Nuqs is a type-safe state management library for Next.js search parameters. It provides a React hook that works like useState but syncs with URL query strings, handling parsing and serialization of JavaScript data types automatically. Built for developers who need consistent, type-checked access to URL parameters in Next.js applications, the package is used by companies including Vercel and Auth.js.
written from the facts on this page · September 2026
From the sources
Type-safe search params state management for React. Like useState, but stored in the URL query string.
End-to-end type safety between Server and Client components. Supports Next.js (app & pages routers), React SPA, Remix, React Router, TanStack Router, and more. Replace or append to navigation history and use the Back button to navigate state updates. Shallow updates by default, opt-in to notify the server to re-render RSCs (with throttle control). Type-safe search params access in nested React Server Components. No prop drilling needed. Support for useTransition to get loading states on server updates. Tested against every Next.js release. Use the provided test adapter to test your components in isolation. I started building my own hook helpers for handling URL states and had to deal with…from nuqs.47ng.com
In the maker’s words, at launch
Next.js has APIs to read and update search params (the /?foo=bar part of the URL), but they lack type-safety for consistent keys and proper parsing/serializing of JS data types. I found myself repeatedly building the same custom hook to get a React.useState-like approach. In 2021, I published it to NPM and…
Does a similar job
all alternatives →
Frontend Fuzzy Search2024 · github.com · ▲120I have spent several years working on search engines in the backend and have now utilized that experience to develop a fuzzy search library for the frontend. It's fast, accurate and can be used for all languages. It should be easy to integrate into your Javascript / Typescript projects. If you test it and find any edge cases that did not work for you please let me know. The implementation is based on 3-grams by the book, augmented with a novel trick of sorting the characters within the 3-grams for enhanced accuracy. For a detailed explanation you may refer to my related blog post at…
Open-Source Auth for NextJS / React2021 · ory.dev · ▲107Add open source login to any Next.js and React single page app (SPA) using free open source.
The Road to GraphQL2018 · robinwieruch.de · ▲122Your journey to master pragmatic GraphQL in JavaScript
React and Next.js Snippets2022 · marketplace.visualstudio.com · ▲133React and Next.js snippets with TypeScript
- AJA JavaScript UI library for imperative JSX2024 · npmjs.com · ▲41
I've been building a web UI library for a side project of mine. I thought it might be useful to others, so I'm releasing it as open source. To put it simply, I realized that most of my pain points with React come from its declarative model ui=f(state). So I'm trying something that I'm calling "imperative JSX." Instead of treating JSX as the source of truth for your UI, it essentially becomes a query interface for DOM manipulation. I first had the idea for it a few months ago, and only began writing it in earnest last week, so it's extremely early and nowhere near production-ready. Still, I'd…
The Next.js Starter Kit with TypeScript, Auth, Postgres, etc.2020 · github.com · ▲7A starter project for next js with authentication - Contains React 17 + Typescript + Tailwind CSS 2 + React Query 3 + GitHub Auth + LinkedIn Auth + Password-less Auth + Fauna DB + ESLint + Prettier + Husky - pbteja1998/nextjs-starter
More ai this month
the category →



Paintings by AI models: programs run through a simulation of oil paint.
AI · 21d ago · stillwet.art
PixVerse R2▲381A real-time world model you can explore and change
AI · 29d ago · world.pixverse.video

Source: Show HN post ↗ · launch text quoted in part
Launched alongside, August 2024
the whole month →



Jupitrr AI▲1,195Jupitrr AI turns raw talking videos into scroll-stopping content for coaches and consultants. Research, script, record, edit, and publish in one app.
AI · 2024 · jupitrr.com

Hey there HN! We’re Joe and Stopa, and today we’re open sourcing InstantDB, a client-side database that makes it easy to build real-time and collaborative apps like Notion and Figma. Building modern apps these days involves a lot of schleps. For a basic CRUD app you need to spin up servers, wire up endpoints, integrate auth, add permissions, and then marshal data from the backend to the frontend and back again. If you want to deliver a buttery smooth user experience, you’ll need to add optimistic updates and rollbacks. We do these steps over and over for every feature we build, which can…
Dev tools · 2024 · github.com