> ## Documentation Index
> Fetch the complete documentation index at: https://docs.krews.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# Installation

> Install and run Celestia nodes (Light, Full Storage, Bridge) with a simple, production-ready workflow. This guide covers network selection for Mainnet and Mocha testnet.

> [!NOTE]
>
> This guide focuses on **celestia-node** (DA network) with optional notes for **celestia-app** (consensus). The steps below are intentionally minimal and point to the official docs for version specifics.

## Prerequisites

* Ubuntu 22.04+ (or any modern Linux)
* `curl`, `jq`, `git`, `wget`, `make`
* Open the following ports on your firewall:
  * **2121** P2P
  * **26658** RPC
  * **26659** REST Gateway (optional)

**1. Install celestia-node binary**

```bash theme={null}
# Build from source (recommended official path)
cd $HOME
rm -rf celestia-node
git clone https://github.com/celestiaorg/celestia-node.git
cd celestia-node

# Install (installs 'celestia' and 'cel-key' binaries to $GOBIN if configured)
make node-install

# Verify
celestia version
cel-key --help
```

**2. Choose your network**

Common options:

* **Mainnet**: `--p2p.network celestia`
* **Mocha testnet**: `--p2p.network mocha` (alias: `mocha-4`)

Your node store will be created under `~/.celestia-<type>-<network>` (e.g., `~/.celestia-light-mocha-4`).

**3. Run a Light Node (recommended to start)**

```bash theme={null}
# Initialize (creates key + config)
celestia light init --p2p.network mocha

# (Optional) Quick sync via trusted hash & height — see Quick Start guide for details
# Start the node, pointing to a consensus RPC endpoint
celestia light start --p2p.network mocha       --core.ip rpc-mocha.pops.one       --core.port 9090
# Mainnet example:
# celestia light start --p2p.network celestia --core.ip <mainnet-rpc-host> --core.port 9090
```

> [!NOTE]
>
> Replace the RPC host with a reliable endpoint (your own, or a known public one). Using a trusted hash/height speeds up first sync—see the Quick Start guide.

**4. Run a Full Storage Node**

```bash theme={null}
# Initialize the store
celestia full init --p2p.network celestia

# Start
celestia full start --p2p.network celestia
# Testnet example:
# celestia full start --p2p.network mocha
```

Full storage nodes store block data and serve light nodes.

**5. Run a Bridge Node**

```bash theme={null}
# Initialize
celestia bridge init --p2p.network celestia

# Start — requires access to a consensus endpoint (celestia-app RPC/gRPC)
celestia bridge start --p2p.network celestia       --core.ip <consensus-rpc-host>       --core.port 26657
```

The bridge node connects the DA layer with consensus (celestia-app). Ensure your **celestia-app** RPC (26657) and gRPC (9090) are reachable.

**6. (Optional) Install celestia-app (consensus)**

```bash theme={null}
# Fastest: download prebuilt (see official docs for latest)
# Or build from source:
cd $HOME
rm -rf celestia-app
git clone https://github.com/celestiaorg/celestia-app.git
cd celestia-app
make install

# Verify
celestia-appd version
```

If you run your own **celestia-app** endpoint, you can point light/bridge nodes at it via `--core.ip` and `--core.port`.

## Service management (systemd)

Below is a minimal template for a **light** node. Adjust `ExecStart` for `full` or `bridge` accordingly.

```bash theme={null}
sudo tee /etc/systemd/system/celestia-light.service > /dev/null <<EOF
[Unit]
Description=Celestia Light Node
After=network-online.target

[Service]
User=${USER}
ExecStart=$(which celestia) light start --p2p.network mocha --core.ip rpc-mocha.pops.one --core.port 9090
Restart=on-failure
RestartSec=5
LimitNOFILE=65535

[Install]
WantedBy=multi-user.target
EOF

sudo systemctl daemon-reload
sudo systemctl enable celestia-light
sudo systemctl start celestia-light
journalctl -u celestia-light -f -o cat
```

## Verify & Health

```bash theme={null}
# Check process
celestia version

# RPC (celestia-node)
curl -s localhost:26658/health

# P2P check (firewall/ports)
ss -ltnp | grep -E "2121|26658|26659"
```

> [!NOTE]
>
> For issues, see the official troubleshooting page and confirm required ports: **2121** (P2P), **26658** (RPC), **26659** (gateway). Keep your binaries updated per the official guides.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.