A visual journey through decentralized application concepts
By the end of this lesson, you'll understand:
Estimated time: 15-20 minutes • Use with: Tutorial Steps or standalone
This lesson builds on concepts from the Vibes to App workshop (by Ramiro Ramirez), extending traditional app development into the decentralized world. We'll use visual aids to explain how Arkiv, a decentralized database, enables true data ownership and independence.
Content adapted from the Arkiv Litepaper with permission. See full litepaper for complete details.
Let's understand the fundamental shift from traditional apps to serverless dapps. These concepts form the foundation for everything you'll build.
The most fundamental difference between traditional apps and serverless dapps is where and who owns the data.
Traditional Apps: Data lives in company databases. When you use a service, your data belongs to that company. If the service shuts down, your data may be lost. You're locked into their infrastructure.
Serverless DApps with Arkiv: Data lives on-chain, owned by users. Your data persists independently of any service. Multiple apps can read the same data. No vendor lock-in. (Source: Arkiv Litepaper)
Side-by-side comparison of a traditional app where data is stored in a company database versus a serverless dapp where data is stored on the Arkiv network and owned by the user.
If you've taken the Vibes to App workshop (by Ramiro Ramirez), you're already familiar with building apps using React, Next.js, and a database. The good news? Most of your stack stays the same. We're just replacing the database layer.
What stays: React for UI, Next.js for framework, TypeScript for types, Vercel for deployment. All your frontend skills transfer directly.
What changes: Instead of PostgreSQL, MongoDB, or Firebase, you use Arkiv, a decentralized database that stores data on the blockchain. The query interface feels familiar, but the data lives on-chain.
Comparison of the Vibes to App development stack with the Serverless DApp stack, highlighting Arkiv as the new decentralized data layer.
This tutorial offers two paths to build your first Arkiv app. Both lead to the same result: a working decentralized application.
Use AI coding assistants (Cursor, Copilot, Claude) with provided prompts. Faster if you're comfortable with AI tools.
Follow step-by-step instructions. No AI needed. Great for learning every detail.
If you've taken the Vibes to App - Class 1 workshop, you've learned how to turn app ideas into working applications. This tutorial extends those concepts into the decentralized world.
Vibes to App taught you:
Serverless DApp 101 extends this to:
Conceptual progression showing how ideas from the Vibes to App workshop extend into serverless and decentralized application concepts.
Understanding the difference between "serverless" and "truly fully serverless" helps you make better architecture decisions.
A "serverless" website is like a restaurant that doesn't own a kitchen. When someone orders food, a kitchen appears, cooks the dish, then disappears. You still get food. You just don't run the kitchen.
A Next.js app on Vercel can feel like a static website, but it's not automatically "no server." It's a blend:
So "serverless apps" plus decentralized data (Arkiv) doesn't remove server-like responsibilities. It moves them into functions, middleware, and client logic.
A "truly fully serverless" app means: no privileged backend you control is required for the app to function. Users can load a client and interact with the system using their own keys, and the system's state lives on infrastructure that's public, replaceable, and verifiable.
A system is "fully serverless" if:
If any of those fail, it's not "fully serverless," it's "server-minimized."
A practical target you can actually ship: "Walkaway-safe serverless." Your Vercel functions exist only for convenience (caching/proxying). The app remains usable without them. Multiple frontends can exist. Data is verifiable and portable.
Real systems in production meet most of the "fully serverless / walkaway-safe" criteria, but no mainstream app yet hits every requirement without tradeoffs. Reality is lumpy. That's instructive.
Systems that are truly serverless exist: BitTorrent, Bitcoin, low-level protocols.
Systems that are usable exist: Ethereum apps with serverless cores, Nostr, ENS plus IPFS frontends.
What no one has fully solved yet:
You are not trying to invent something that has never existed. You are trying to compose known working pieces into something that normal users can tolerate, builders can fork, and institutions can't quietly capture. That's a harder problem than "no servers." It's the problem of durable freedom under real constraints.
Now let's see how data actually flows through a serverless dapp. These visuals show the mechanics of reading and writing to Arkiv, and how to verify your data on the blockchain.
When you create a record in your app, here's what happens behind the scenes:
Important: Indexer lag is normal! Your transaction is confirmed on-chain immediately, but it takes a few seconds for indexers to process it. This is why you might need to refresh to see new data. (Source: Arkiv Litepaper - Indexer Architecture)
Write flow showing how a user action becomes a signed Arkiv transaction recorded on the blockchain and visible in the explorer.
Reading data from Arkiv is simpler than writing. No authentication is needed, and it's free!
Key Points: Reads are public (anyone can query), free (no gas fees), and fast (served by indexers). Queries use attributes for filtering. Think of them like indexed database columns. (Source: Arkiv Litepaper - Query Interface)
Read flow showing how application data is queried from Arkiv and displayed in the user interface.
Every piece of data in Arkiv is stored as an entity. Understanding entity structure is key to building effective queries.
Entity Components:
type, spaceIdwallet, created_atapplication/json)Pro Tip: Use attributes for anything you want to query on. Store complex data in the payload as JSON. Attributes are indexed and fast; payloads are for richer content.(Source: Arkiv Litepaper - Entity Model)
Diagram of an Arkiv entity showing its unique ID, queryable attributes, content payload, and transaction hash used for verification.
The "walkaway test" is a simple but powerful concept: Can your app and data survive if you shut down your server?
Why This Matters: With Arkiv, your data lives on the blockchain, not in a company database. This means you can shut down your server, rebuild your app from scratch, or switch hosting providers. Your data remains accessible. This is true decentralization. (Source: Arkiv Litepaper - Data Persistence)
Comparison showing that data stored in a traditional app is lost when the app shuts down, while data stored on Arkiv remains accessible to new applications.
One of the most powerful features of blockchain-based data is verifiability. Anyone can verify that your data is actually on-chain.
Blockchain Transparency: All Arkiv data is public on-chain. This means anyone can verify your data, see transaction history, and trust that the data hasn't been tampered with. For privacy, use unique space IDs or encrypt payloads.(Source: Arkiv Litepaper - Blockchain Verification)
Step-by-step flow showing how a transaction hash is used to verify data on the blockchain using the Arkiv explorer.
Now that you understand the concepts, here are tools and patterns to help you build Arkiv apps correctly from day one.
The Arkiv AI Agent Kit is a drop-in LLM context designed to help AI coding assistants (Cursor, Copilot, Claude, etc.) build Arkiv integrations correctly from day one.
What It Does:
How to Use:
Key Principles from the Kit: Indexer lag is normal (not an error), wallet normalization everywhere, query shape standardization (type + spaceId + limit), immutable history design, and timeout handling for all writes.
The AI Agent Kit is available in the tutorial repository's extractions folder. See the Next Steps section for more details.
type, spaceId, and limit in queriesThese patterns come from arkiv-app-kit and arkiv-ai-agent-kit. See the Next Steps section for more resources.