dartpub.dev DartNative · beta
Guides/Publishing

Publisher guide

From a repository to a published plugin, in one sitting. Every plugin on dartpub is free and open source — publishing is how you share it, and adoption is how it starts paying your framework subscription back.

1 · What you need

  • A dartpub.dev account (sign in with GitHub).
  • Your plugin in a public GitHub repository you own — your account, or an org you admin.
  • An open-source license on that repo: MIT, BSD 3-Clause, or Apache 2.0. Copyleft licenses aren't accepted — they would impose obligations on the closed apps that link your plugin.

2 · Register the plugin

Go to Publish a plugin. Three steps:

  1. Repository — paste your repo URL. We verify you control its namespace; we never read the contents. The package name pre-fills from the repo name (lowercase, snake_case, 2–32 chars — it's what users add to their pubspec, and it's global across dartpub).
  2. License — pick the license your repository carries.
  3. Review & publish — icon, tagline, description, and your acceptance of the Plugin Publishing Agreement.

Registering reserves the name and creates the plugin page as unlisted. It goes live once it has a README, an example, and a published version.

3 · Ship the first version

From your plugin's directory:

dn plugin publish

One command does everything: builds the binary (iOS .xcframework + Android .aar + Dart bindings), pushes your README.md and example/ as the plugin page's Readme and Example tabs, and archives the version's source with the registry — so apps that depend on your plugin keep working even if the repository later disappears.

Have a CHANGELOG.md? The section matching the version you're shipping (e.g. ## 0.2.0) becomes that version's notes in the Changelog tab.

4 · Keep it current

  • New version: bump the version in your pubspec and run dn plugin publish again.
  • Docs-only fix: dn plugin sync refreshes the Readme/Example tabs for the current version — no rebuild.
  • Issues: your repository's own GitHub issue tracker is the plugin's issue home.

5 · The Contributor program

Once apps ship with your plugin you become a contributor, and pay half price for your framework subscription — or $1 a year, based on adoption — plus the Contributor badge. Nothing to claim, nothing to apply for: it's automatic. How the Contributor program works →