Skip to main content

Kotlin Quickstart

The quickest way to start building Solana Kotlin dApps is to build off the Solana Jetpack Compose Scaffold.

Solana Jetpack Compose Scaffold

The scaffold app serves as both a starting implementation and an example reference of how to use the core Kotlin SDKs, like web3-core, rpc-core, and Mobile Wallet Adapter.

It includes:

  • Core Solana kotlin libraries
  • Pre-built Compose UI components,
  • Code examples of transaction building and RPC requests.
Scaffold dApp Screenshot 1
Scaffold dApp Screenshot 2
Scaffold dApp Screenshot 3

Prerequisites

Follow the prerequisite setup guide to set up Android Studio, your Android Device/Emulator and install a MWA-compatible wallet, like fakewallet.

Install the Jetpack Compose Scaffold

Clone the repo

The scaffold app is open source and can be fetched from Github.

git clone https://github.com/solana-mobile/solana-kotlin-compose-scaffold.git

Open the project in Android Studio

In Android Studio, open the project with File > Open > SolanaKotlinComposeScaffold/build.gradle.kts

Build and run

Ensure you have connected an Android emulator or device and it is detected by Android Studio. If not, follow this guide to setup your emulator/device.

In the top bar of Android Studio, select "app" as the configuration and your emulator/device, then click run.

Build and run the app

If successful, the scaffold app will launch on your emulator/device.

Connect with a locally installed wallet app to start interacting with the Solana network! 🎉

Further learning

To learn how to better use the core Solana Kotlin SDKs, check out these developer guides.