The Problem: Onboarding Friction
You built something great. Your users land on it and... freeze. They don't know where to click. What does that button do? Why should they care about feature X before feature Y?
Product tours fix this. They guide users through your app step by step, showing them what matters first. But most tour tools require a dashboard, authentication, monthly fees, or adding a bulky script tag to your HTML.
There's a better way.
Enter Lightweight Tours with Code
What if you could add interactive product tours the same way you add any other npm package? Install it. Import it. Pass it a configuration object. Done.
No account creation. No external dashboard. No waiting for some service to load. Just JavaScript that lives in your repo.
How to Build a Tour in 5 Minutes
Let's walk through it. First, install the runtime:
npm install @trailguide/runtime
Now create a tour config. This is just a JavaScript object describing your steps:
const onboardingTour = {
steps: [
{
target: '.hero-button',
title: 'Welcome!',
description: 'Click here to get started',
position: 'bottom'
},
{
target: '.dashboard-nav',
title: 'Navigate Your Workspace',
description: 'Use this menu to explore all features',
position: 'right'
},
{
target: '.settings-icon',
title: 'Customize Your Experience',
description: 'Your preferences are here',
position: 'left'
}
]
};
Then drop the Trailguide component into your React app:
import { Trailguide } from '@trailguide/runtime';
import onboardingTour from './tours/onboarding';
function App() {
const [tourActive, setTourActive] = useState(false);
return (
<>
<Trailguide trail={onboardingTour} isActive={tourActive} />
<button onClick={() => setTourActive(true)}>
Start Tour
</button>
{/* Your app content */}
</>
);
}
That's it. Your tour is live.
Why This Matters
Most tour tools make you choose between simplicity and control. This doesn't. You get both.
Because the tour lives in your code, you can:
- Version control it alongside your features
- Test it with the same CI/CD pipeline you already use
- Deploy it instantly without waiting for a backend
- Keep all your onboarding logic in one place
- Customize styling to match your brand (it's just CSS)
The whole runtime is only 13kb gzipped. It won't bloat your bundle. And it's MIT-licensed, so you can use it however you want, including in commercial products.
Real Use Cases
Product tours aren't just for onboarding newbies. Use them for:
- Highlighting new features when you ship updates
- Guiding power users to pro features they haven't discovered
- Reducing support tickets by showing users how to do common tasks
- A/B testing different onboarding flows (since it's in your code, you can branch it)
Beyond Tours
If you want to go deeper, Trailguide also includes analytics (see which steps users actually complete), Playwright test helpers (ensure tours don't break), and a Pro tier with advanced features. But the core runtime handles tours beautifully on its own.
The philosophy is simple: give developers what they need in the free version. Make it lightweight. Make it yours.
Ready to guide your users better? You can try Trailguide free at gettrailguide.com.
Top comments (0)