> For the complete documentation index, see [llms.txt](https://docs.polysmartchain.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.polysmartchain.com/developer/release-prc-20-token.md).

# Release PRC-20 Token

Before you start, you will need to prepare the following:

1. MetaMask Wallet
2. Have at least 1 PSC

### Start using Remix <a href="#getting-started-with-remix" id="getting-started-with-remix"></a>

Now you can start [Remix](https://remix.ethereum.org/) to proceed. You need to create a new file to save the Solidity smart contract. Click the **+** button below **File Explorers** and enter the file name "MyToken.sol" in the pop-up window.

![](/files/yjLSopNJUiO5bOoqEBVi)

Next, paste the following smart contract into the edit box of the pop-up window.

```
pragma solidity ^0.7.0;

import 'https://github.com/OpenZeppelin/openzeppelin-contracts/blob/release-v3.2.0-solc-0.7/contracts/token/ERC20/ERC20.sol';

// This ERC-20 contract mints the specified amount of tokens to the contract creator.
contract MyToken is ERC20 {
  constructor(uint256 initialSupply) ERC20("MyToken", "MYTOK") {
    _mint(msg.sender, initialSupply);
  }
}
```

![](/files/4ToxGNl4Rz50IuzB097q)

This is a simple version of the ERC-20 contract written based on the latest OpenZeppelin ERC-20 template. The contract uses `MYTOK` as the symbol for`MyToken`and minting the initial Token for the contract creator.

Next, guide to **Compile** in the side options and click on the **Compile MyToken.sol** button.

![](/files/aKIBNUKsZp9VKjMQLrbr)

You will see that Remix has downloaded all OpenZeppelin dependencies and finished compiling the contract.

When you select the **Injected Web3** option, you need to authorize Remix to connect to your MetaMask account.

![](/files/RrCjDuSn54yOWEtAJteJ)

Then go back to the Remix screen and you will see that the account you want to deploy is already authorized to login via MetaMask. Next to the **Deploy** button, enter the Token amount, let's say we want to deploy 10 million Tokens, but since the default number of digits in this contract is 18 decimal places, you need to enter `10000000000000000000000000` in the input box.

![](/files/4TQOu82kqAv1GnuyLzyp)

MetaMask will then pop up a window asking you to confirm the transaction for this deployment contract.

![](/files/l8R4VzOJggKwBC0gXkWu)

After you click **Confirm**, the deployment will be completed and you will see your transactions on MetaMask. At the same time, the contracts will also appear in Remix under **Deployed Contracts**.

![](/files/73sdj2MhCyhiXtuL0eP6)

Once you have successfully deployed the contract, you can interact with the smart contract via Remix.

Scroll down the page, find **Deployed Contracts**, click on **name**, **symbol**, and **totalSupply**, and `MyToke`, `MYTOK`, and `10000000000000000000000000`will appear respectively.If you copy the contract address and paste it into the **balanceOf** field, you will see the full balance of the account at the user's ERC-20 address. Click on the button next to the contract name and address to copy the contract address.

![](/files/C2ZGIL2hf5mFcve6Droz)

Now, open MetaMask and add the ERC-20 Token you just deployed, make sure you have copied the contract address on Remix before doing so. Go back to MetaMask, as shown below, and click **Add Token**. Make sure that the account you are working with is the account where the contract has been deployed.

![](/files/AdY9A8mwJZci1k9OUKRR)

Paste the copied contract address into the **Custom Token** field, while the **Token Symbol** and **Decimals of Precision** fields will be automatically populated.

![](/files/DJxuVGNIGRmGgYSj9y9c)

After clicking **Add Token**, you will see that 8 million MyTok have been successfully added to your account:

![](/files/zXvqSYwLHqSvH47QfWed)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.polysmartchain.com/developer/release-prc-20-token.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
