How to Create an SPL Token

A fairly nontechnical introduction.
The most authoritative source on how to create an SPL token is the documentation of the Solana Progam Library. Naturally, that’s a rather technical source. There is also this how-to video (plus this follow-up), which takes a similarly technical approach. This page describes a less technical (but also less feature complete) approach.‌

Buying SOL

SOL is used on the Solana blockchain to pay for transaction costs. Creating the tokens and sending them around will cost the SOL equivalent of a few dollar cents and creating a market on Serum will cost some $100–200 in SOL. So it’ll make sense to get a $1 worth of SOL in any case, or a lot more if you want to create the market.‌

Opening an Exchange Account

One way to buy cryptocurrencies is to open an account with an exchange. I use FTX. I don’t know what “FTX” stands for, but otherwise it’s remarkably intuitive to use. (I don’t think it’s “Financial Times eXchange.”) You can create an account with FTX here.​‌
That link includes a referral code that give us both a 5% fee discount. If you want to support a friend instead who has an FTX account, then ask them for a referral link instead.‌
If you want to look for alternatives, check whether they support the SPL token program. The alternative would be to send (Ethereum-based) ERC-20 SOL, and that costs a lot more in transaction costs. (Some $10–100 instead of‌ < 1 cent.)

Funding the Account

​The wallet page should look sort of like this.​
The wallet balances on FTX.
You can click “deposit” next to the currency that you want to send to the account. There will be instructions and warnings. Read them carefully to make sure your money doesn’t get lost in transit.
If you only want to create your token, then $1 should be enough. If you want to also list a market on the Serum exchange to trade your token, you’ll need some $100–200 or about 4 SOL at the time of writing, June 2021.‌
If you want to fund your account with something other than USD, such as GBP, make sure “hide zero balances” is not shown or disabled, and search for the currency.
Some currencies don’t have markets on FTX, in which case you’d have to pay for the conversion to USD. If you can click the name of the currency, it’ll lead you to the market. If not, there is no market.‌
Fiat deposits can take a few days to arrive. Crypto deposits are typically faster.‌

Actually Buying SOL

Once you have USD on FTX, you can use it to buy SOL on the SOL/USD market.​
Buying 5 SOL (June 21, 2021).

​Creating a Solana Wallet

Admittedly, it sounds like you already have a wallet on FTX, but that’s technically FTX’s wallet, and you only have limited access to it through FTX. FTX always warns: “Only [specific coin] should be sent to this address! Sending any other coins may result in the loss of your deposit.” So let’s not do that.
Instead we can create a Sollet wallet.
Creating a wallet.
Make sure to store the words safely, in order, and in lowercase. Copy variant spellings faithfully even you might not usually use them.
You can weave them into a sentence and write them into a notebook, write a nonsensical letter that features them and send it to a trusted person, and then also put them into your password manager (such as 1Password or Bitwarden). Money is more often lost through lost pass phrases than through attacks, or so I’ve heard.
​There are some providers other than Sollet. The fellow in the abovelinked video picked Phantom, which I’m also favoring now. They’re all noncustodial wallets, so you can switch between them later. I first used a Bonfida wallet and then switched to Sollet, which was no problem at all. The SPL Token UI currently uses Sollet, so you could start with a Sollet wallet and later import it into Phantom.

Depositing SOL to the Wallet

The deposit address for SOL on Sollet.
Your wallet should look roughly like the image above. You click on SOL, then on “receive,” and it’ll look even more like the image above. Now you can copy out the deposit address. (It’s also known as the public key of your wallet.)
Withdrawing SOL from FTX.
You can find your SOL on FTX on the wallet page either by hiding zero balances (the tick box) or with Ctrl+F (the SOL search).
You click “withdraw,” enter the amount (e.g., the maximum amount), paste the deposit address, optionally save it for next time, enter your 2FA code if applicable, and withdraw. It should hit your Sollet wallet within seconds.

Creating, Minting, and Supply-Capping the Token

The typical, secure, and feature-complete way to create tokens is through the command line as shown in the SPL documentation. But Paul Schaaf has created the SPL Token UI, which may be easier to use for some of us.
I haven’t audited the SPL Token UI code.

Creating the Token

Paul’s SPL token creator.
Click “Derive public key from external wallet” and log in to your Sollet wallet. You can leave the freeze authority empty. (I suppose your ability to freeze the tokens would make them less appealing for investors? I may be misunderstanding how this works.)
Many SPL tokens seem to use 6 decimals. I don’t know what the ins and outs are, but 6 seems to be what a lot of knowledgeable Solana users opt for.
You can take inspiration from the tokens listed on Solscan.
After you click “Create new token,” you’ll need to confirm the transactions in the Sollet window. Finally, you’ll hopefully see a success message displayed on the SPL token UI website with a link to the Solana Explorer. Note the account address.

Minting the Token

The account editor allows you to mint token. “Mint” is selected by default, but make sure of that. Enter the new account address from the previous step.
Deciding the amount is a very consequential step. Some projects I know seem to have gone for a supply of 10 billion tokens. But people will tend to distrust or at least not value highly tokens whose ratio of tokens on the market to minted tokens is very small, especially if they’re owned by very few accounts, which aren’t controlled by, for example, vesting-related smart contracts.
Then again you can later burn tokens, so starting with a high supply may not be a bad idea. If you went for 6 decimals in the previous step, you have enter 10 billion times 10⁶ = 10 quadrillion = 10,000,000,000,000,000. Odd, but it says so in the dialog.
Minting new tokens.
Commence the process with “Mint to account” and confirm the transactions.

Limiting the Supply

If people don’t trust tokens if there is a high capped supply in someone’s wallet, then they certainly don’t trust a token whose supply is not capped at all. So after minting the tokens, you’ll want to make it forever impossible to mint more of them for you and everyone else.
Please confirm that the desired number of tokens have found their way to your wallet safely.
You’ll need the token editor for this.
The token editor.
Enter the token address (not the account), make sure the toggle points to “Edit mint authority” (since we didn’t set a freeze authority in the first place), and leave the “New mint authority” empty.
Once you click “Edit token” and confirm the transactions, your token supply is forever limited to the number of tokens you have minted.
All of these transactions should together have cost you less than a dollar.

Naming the Token

It might be that you would like to name your token. This is optional. To do so, you create a pull request in the Token List repository.

Creating a Market on the Serum Exchange

This is a costly and optional step. If someone wants to invest in your project, they trust you, so you can probably send each other the tokens directly. Then again, if your project gets big, you may want it to be traded on a liquid market. But then the fees for creating the market on Serum are probably not prohibitive anymore either.
Note also that Burnt Finance is building auctions. Once that is live, you can use a bonding curve auction to establish a market for your token. I don’t know whether Burnt will be based on Serum though. If not, you can use an auction to gauge the interest, and then create the Serum market only if there is enough interest to warrant it.
But if desired, you can head over to the DEX interface of Project Serum itself or to any of the other interfaces to list a new market.
List a new market on Serum.
Make sure to connect your wallet, then enter your token address as base token. USDC (as in the screenshot) is a good choice for a quote currency.
I don’t know what good choices are for the remaining two values. It looks like SOL, SRM, and FTT use 0.1 for the size and 0.001 for the USDC price. So maybe that’s a good choice.
If you get a descriptive error message like “System program error 1,” it probably means that your SOL balance is too low. You can dig through the failed transactions until you find a message like “Transfer: insufficient lamports 12345678, need 1234567890.” A lamport is 0.000000001 SOL. But I suspect there are several transactions like that, so you’ll need more SOL than it says in whichever transaction you find. The documentation says it’s 4 SOL at the moment.​
Adding a market to the UI.
To trade on the market, you use the plus button next to the dropdown with the market list.
Last modified 2yr ago