---
title: Package the Plugin File and Publish it
---


{/* 
  CONTRIBUTOR NOTE:
  ----------------
  This is a legacy document that is being deprecated.
  Please DO NOT make changes to this version.
  All updates should be directed to the new version at:
  /plugin-dev-en/0322-release-by-file
*/}

<Card title="This Documentation is Being Deprecated" icon="circle-exclamation" href="/plugin-dev-en/0322-release-by-file">
  <p>This page is being phased out as part of our documentation reorganization.</p>
  
  <p><strong>Click this card</strong> to be redirected to the updated version with the most current information.</p>
  
  <p>If you notice any discrepancies or areas needing improvement in the new documentation, please use the "Report an issue" button at the bottom of the page.</p>
</Card>

After completing plugin development, you can package your plugin project as a local file and share it with others. Once the plugin file is obtained, it can be installed into a Dify Workspace. This guide will show you how to package a plugin project as a local file and how to install plugins using local files.

### **Prerequisites**

You'll need the Dify plugin development scaffolding tool for packaging plugins. Download the tool from the [official GitHub releases page](https://github.com/langgenius/dify-plugin-daemon/releases).

See the [Install Development Tools](../quick-start/develop-plugins/initialize-development-tools.mdx) tutorial for dependency installation and configuration steps.

Select and download the version appropriate for your operating system from the release assets.

Using **macOS with M-series chips** as an example, download the `dify-plugin-darwin-arm64` file, then navigate to the file's location in terminal and grant execution permissions:

```bash
chmod +x dify-plugin-darwin-arm64
```

For global use of the scaffolding tool, it's recommended to rename the binary file to `dify` and copy it to the `/usr/local/bin` system path.

After configuration, enter the `dify version` command in terminal to verify version number output.

### **Packaging Plugins**

After completing plugin project development, ensure remote connection testing is done. To package plugins, navigate to the parent directory of your plugin project and run the following packaging command:

```bash
cd ../
dify plugin package ./your_plugin_project
```

After running the command, a file with `.difypkg` extension will be generated in the current path.

![](https://assets-docs.dify.ai/2024/12/98e09c04273eace8fe6e5ac976443cca.png)

### **Installing Plugins**

Visit the Dify plugin management page, click **Install Plugin** → **Install via Local File** in the top right corner, or drag and drop the plugin file to a blank area of the page to install.

![](https://assets-docs.dify.ai/2024/12/8c31c4025a070f23455799f942b91a57.png)

### **Publishing Plugins**

You can share the plugin file with others or upload it to the internet for download.

{/*
Contributing Section
DO NOT edit this section!
It will be automatically generated by the script.
*/}

---

[Edit this page](https://github.com/langgenius/dify-docs/edit/main/en/plugins/publish-plugins/package-plugin-file-and-publish.mdx) | [Report an issue](https://github.com/langgenius/dify-docs/issues/new?template=docs.yml)

