Getting Started with Solana Development

by Solana Foundation

Getting Started with Solana Development

In this article you’ll learn about some of the very high level topics related to Solana development such as myths, development workflows, programs, dApps (decentralized application), and client SDKs that will give you a clear path to developing on Solana. This article is intended for developers that are new to Solana and assumes you already have some general knowledge around blockchain development for things like dApps, Smart Contracts and tokens. If all of this makes sense then this article is definitely for you. Now let’s get started!

Myth Busting Solana Development

The very first thing that I think is important for any new developer coming into the Solana Ecosystem to understand is that it is not a requirement that you have experience with smart contracts or Rust to get started building on Solana. In fact, you don’t need blockchain experience at all. In Solana, smart contracts are called Programs. Rust C, C++ are the languages used to build programs that are deployed on-chain. Solana Programs are vital to building unique and powerful tools on-chain, but the good news is that there are already a lot of programs available for you to interact and build with. You can build dApps similar to how web 2 and web 3 developers build web apps in centralized applications with 3rd party SDKs. The only difference is that with dApps you’re storing data on a blockchain rather than on a centralized database and the transaction/storage cost is paid for by your users. The term blockchain has a tendency to intimidate a lot of developers, but it’s really not intimidating once you take the time to understand what it actually is.


Solana Development Workflows


As mentioned previously, you aren’t required to know Rust or understand on-chain programs to build on Solana, although once you’re comfortable with building dApps you’ll likely want to learn how to create your own programs. On Solana, and most smart contract blockchains, there are two completely different development workflows.


Program (smart contract) development on Solana is done in Rust, C and C++. These programs are built and deployed on-chain and are run via the Solana Runtime where they live forever. These programs can be used by anyone who knows how to communicate with them by submitting transactions with instructions to the network via the JSON RPC API or any SDK built on top of this API. Other on-chain programs can also make use of the JSON RPC API.


dApp development is something that most web 2 and web 3 developers will be more familiar with. This type of development involves creating applications that send transactions with instructions to on-chain programs and very closely resembles building web/mobile apps and interacting with centralized APIs. The foundation of app development on Solana is the JSON RPC API which is a layer of communication that allows you to interact with the blockchain. Solana Labs has created an easy to use solana-web3.js SDK that allows you to talk to the blockchain and Solana programs in a way that feels just like talking to any other API you’ve used. There are many 3rd party SDKs that have also been built on top of the JSON RPC API such as Java, C#, Python, Go, Swift, Dart-Flutter and Kotlin. You can access these SDKs on the Solana Developers Page.


Each of these SDKs gives you the power to build fully functional dApps on Solana in your favorite languages. Once you’ve mastered the Solana API you can then start to understand how to build your own programs in Rust, C or C++.


Programs (Smart Contracts)


We just discussed the development workflows on Solana and you learned that you can develop programs on Solana or you can build dApps using existing programs. Now let’s talk about some of the programs that exist today, created by Solana Labs. There are two sets of programs that are maintained as part of the core software releases, Native Programs and the Solana Program Library (SPL).  Native programs are the core of Solana and the one of the most common of those is the System program. This program is used for things like creating accounts and transferring SOL. Other popular Native programs include the Staking Program and the Voting program. On the other hand, the Solana Program Library includes many different programs, the Token program, Solana's Ethereum ERC-20 equivalent, being one of the most popular. The Token program allows you to interact with tokens on the Solana blockchain including NFTs. Using this program you are able to do many things such as minting, transferring, burning or querying tokens. Between the native and program library programs, you could build some really interesting dApps to start your Solana development journey. I always like to recommend checking out Project Serum’s spl-token-wallet repo which is a React wallet app that uses a combination of Solana’s solana-web3.js SDK and the Token program (using the Token Program JS Bindings) for creating token accounts and transferring tokens.


10,000 Foot Development View


Now let’s take a step back and look at a high level representation of the Solana development workflow. It’s important to note that this is an oversimplification of the Solana network for the purposes of learning in an easy-to-understand way.

Starting at the top left of the diagram (Program) you can see the first development workflow that allows you to to create and deploy custom Rust, C and C++ programs directly to the blockchain. Once these programs are deployed, anyone who knows how to communicate with them, can use them. You can communicate with these programs by writing dApps with any of the available client SDKs (or the CLI), all of which use the JSON RPC API under the hood.


The second development workflow is the dApp side starting on the bottom left (Client) where you can write dApps that communicate with deployed programs. Your apps can submit transactions with instructions to these programs via a client SDK to create a wide variety of applications such as wallets, DEXs and more. These two pieces work together to create a network of dApps and programs that can communicate with each other to update the state and query the blockchain.


Developers can think of Solana as a global computer where anyone in the world can deploy programs to it, and communicate with the ones that already exist.

I’m Ready, How Do I Get Started?

One of the biggest questions I get is where to get started. There are a lot of entry points but I think for developers new to Solana you should be using all the current curated resources on the Solana Developers Page. If you’re brand new to Solana I again recommend starting with Figment Learn Solana Pathway. If you’re already familiar and looking for a starter app try the dApp-scaffold. Good luck developers and we’ll see you soon!