npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

react-performance-profiler

v1.0.1

Published

A React performance profiling and render analysis tool.

Downloads

188

Readme

React Performance Profiler

Understand Every React Render.

Automatically detect unnecessary re-renders, prop instability, and performance bottlenecks in your React applications.

npm version License: MIT Build Status Stars

🚨 The Problem

Debugging React performance is difficult, tedious, and often feels like a guessing game.

  • Finding unnecessary re-renders across a large component tree is extremely time-consuming.
  • React DevTools is powerful, but it shows raw data without actionable explanations or context.
  • Identifying why a set of props caused a component to render involves manual deep-dives and countless console.log statements.

Developers waste hours trying to find the root cause of sluggish application performance.

💡 The Solution

React Performance Profiler analyzes your React component tree in real-time and tells you exactly why components are rendering.

Instead of staring at a waterfall of incomprehensible data, this tool provides human-readable explanations, clear visual indicators, and actionable suggestions to instantly fix performance issues before they hit production.

✨ Features

  • 🕵️ Render Tracking & Cause Analysis: See exactly which state or prop change caused any component to re-render.
  • 🐢 Slow Component Detection: Instantly identify components with rendering times that exceed your performance budget.
  • 🪃 Prop Instability Detection: Catch inline functions and objects that break React's memoization automatically.
  • 📊 Render Heatmap Visualization: Visually spot problematic areas of your app with intuitive heatmaps.
  • 🎯 Optimization Suggestions: Get precise recommendations (e.g., "Wrap Component in React.memo", "Memoize onClick prop with useCallback").
  • ⏱️ Zero Overhead in Production: Safely include in your app; simply disable the provider in your production build.

⚖️ Feature Comparison

| Feature | React Profiler API | React Performance Profiler | | :--- | :---: | :---: | | Measure render time | ✅ | ✅ | | Component render count | ❌ | ✅ | | Render cause detection | ❌ | ✅ | | Performance warnings | ❌ | ✅ | | Optimization suggestions | ❌ | ✅ | | Visual dashboard | ❌ | ✅ | | Flame graphs | ❌ | ✅ | | AI analysis | ❌ | ✅ |

📸 Demo

Get a clear, automated breakdown of your app's performance in real time:

| Performance Report | Status | | :--- | :--- | | 🐢 Slow Components | <DataGrid /> (24ms) - Exceeds budget | | 🔁 Frequent Renders | <Avatar /> rendered 42 times | | 💡 Suggestion | ⚠️ The data prop reference on <DataGrid /> changes every render. Wrap the value in useMemo. |

(Add a screenshot or GIF of your profiler overlay here to maximize conversion)

📦 Installation

Installing react-performance-profiler takes less than a minute.

npm install react-performance-profiler

or

pnpm add react-performance-profiler

or

yarn add react-performance-profiler

🚀 Quick Start

To start profiling, simply wrap your top-level application component with the ProfilerProvider.

import React from 'react';
import { createRoot } from 'react-dom/client';
import { ProfilerProvider, Dashboard } from 'react-performance-profiler';
import App from './App';

const root = createRoot(document.getElementById('root')!);

root.render(
  <React.StrictMode>
    <ProfilerProvider active={process.env.NODE_ENV === 'development'}>
      <App />
    </ProfilerProvider>
    <Dashboard />
  </React.StrictMode>
);

That's it! Your app is now being profiled, and you can view the dashboard alongside your components.

🔺 Using with Next.js (App Router)

Since the profiler relies on React Context and Hooks, it must be rendered as a Client Component in the Next.js App Router.

  1. Create a Client Component wrapper (e.g., components/PerformanceProfiler.tsx):
"use client";

import React from 'react';
import { ProfilerProvider, Dashboard } from 'react-performance-profiler';

export default function PerformanceProfiler({ children }: { children: React.ReactNode }) {
  const isDev = process.env.NODE_ENV === 'development';

  return (
    <>
      <ProfilerProvider active={isDev}>
        {children}
      </ProfilerProvider>
      {isDev && <Dashboard />}
    </>
  );
}
  1. Wrap your application in app/layout.tsx:
import PerformanceProfiler from '@/components/PerformanceProfiler';

export default function RootLayout({ children }: { children: React.ReactNode }) {
  return (
    <html lang="en">
      <body>
        <PerformanceProfiler>
          {children}
        </PerformanceProfiler>
      </body>
    </html>
  )
}

🔺 Using with Next.js (Pages Router)

Wrap your application in pages/_app.tsx:

import type { AppProps } from 'next/app'
import { ProfilerProvider, Dashboard } from 'react-performance-profiler';

export default function App({ Component, pageProps }: AppProps) {
  const isDev = process.env.NODE_ENV === 'development';

  return (
    <>
      <ProfilerProvider active={isDev}>
        <Component {...pageProps} />
      </ProfilerProvider>
      {isDev && <Dashboard />}
    </>
  )
}

⚙️ How It Works

Under the hood, react-performance-profiler operates through a seamless, lightweight architecture designed specifically for modern React:

  1. Profiler SDK: Wraps your components, non-intrusively gathering React Fiber data.
  2. Render Tracking Engine: Tracks commit phases, measuring execution times and deep-comparing prev/next props layer by layer.
  3. Analysis Engine: Evaluates the collected data against known performance anti-patterns (e.g., inline object allocations, excessive render counts).
  4. Dashboard / Overlay: Projects the processed telemetry directly onto your screen, highlighting trouble spots.

🤔 Why This Tool Exists

React's reactive model is brilliant, but it's remarkably easy to introduce hidden performance leaks through a simple mismanaged dependency array or an inline arrow function.

React developers spend hours debugging these render behaviors manually because built-in tools only show that that a render happened, not why it happened or how to fix it. We built this tool to make React performance transparent, accessible, and solvable so you can get back to building features.

🗺️ Roadmap

We're constantly working to make the profiler even more powerful. Upcoming features include:

  • [ ] AI Performance Insights: Automated natural language summaries of complex bottlenecks.
  • [ ] Flame Graph Visualization: Native chronological timeline mapping for deep dive investigations.
  • [ ] Chrome DevTools Integration: A dedicated browser extension panel.
  • [ ] CI Performance Checks: Fail your CI pipeline if a PR introduces significant render degradation.

🤝 Contributing

We love community contributions! Whether you're fixing bugs, adding new visualizations, or improving our documentation, your help makes this tool better for everyone.

Please see our CONTRIBUTING.md for:

  • Pull request guidelines
  • Issue reporting steps
  • Local development instructions & coding standards

📄 License

This project is licensed under the MIT License. See the LICENSE file for more details.