← Back to excelora.in Free courses by the Excelora team · Learn by doing
Hire Excelora

Lesson 3 of 4 · 11 min read

Connecting your app to a backend

The app is only the front. Data lives on a server reached through an API — URLs that return JSON:

const res = await fetch('https://api.example.in/orders', {
  headers: { Authorization: 'Bearer ' + token }
});
const orders = await res.json();

Always use HTTPS, short-lived tokens, and never ship secret keys inside the app — apps can be decompiled.

⚡ Quick check

Can you safely hide a secret API key inside a mobile app?