# Sending a sample of events to Speed Insights

**Author:** DX Team

---

By default, all events are sent to Speed Insights.

To send only a sample of your data, you can add the Speed Insights component with the [`sampleRate`](/docs/speed-insights/package#samplerate) prop to your app's root layout. The [`sampleRate`](/docs/speed-insights/package#samplerate) prop accepts a number between 0 and 1, where 0 is 0% and 1 is 100%:

`import { SpeedInsights } from '@vercel/speed-insights/next'; export default function RootLayout({ children, }: {children: React.ReactNode;}) { return ( <html lang="en"> <head> <title>Next.js</title> </head> <body> {children} <SpeedInsights sampleRate={0.5} /> </body> </html> ); }`

## More resources

- [`@vercel/speed-insight`](/docs/speed-insights/package)[s reference](/docs/speed-insights/package)
  
- [Speed Insights](/docs/speed-insights)

---

[View full KB sitemap](/kb/sitemap.md)
