Back to Blog

Blog

How to Create a shadcn Registry URL in 5 Seconds

Skip the repo setup. Paste your component, get a registry URL, share it instantly.

You just built a component. Maybe it's a magic card with a hover effect, a custom hook for clipboard operations, or a utility function your team keeps copying between projects.

You want to share it. The shadcn way would be to create a registry — but that means setting up a repo, writing the registry JSON schema, hosting it, and maintaining it. For one component. That's friction you don't need.

Here's the fix

pastecn turns any code into a shadcn-compatible registry URL. No repo, no config, no hosting.

1

Paste your code

Open pastecn and paste your component, hook, or utility directly into the editor.

2

Set the type

Choose whether it's a component, hook, lib, or generic file. This determines where it gets installed in the user's project.

3

Click Create

You get a URL. That's it. The URL is a valid shadcn registry endpoint.

What the recipient does

Anyone with the snippet ID can install your component with one command:

terminal
$npx shadcn@latest add @pastecn/abc123

The CLI handles everything — downloading the code, placing it in the right directory, and installing any dependencies. The person receiving your component doesn't need to know anything about registries.

You can also use the full URL: https://pastecn.com/r/abc123

When to use this

Social sharing. Posting a component in a tweet or Discord message.

Quick handoffs. Sending code to a teammate without PR overhead.

One-off utilities. Distributing helper code that doesn't need a package.

Registry prototyping. Testing before committing to full infrastructure.

What you're not getting

This isn't a package manager. There's no versioning, no updates, no dependency resolution. Each paste is immutable — a snapshot of code at a moment in time. If you need those features, set up a proper registry. If you just need to share code fast, paste and go.