Th0rgal/open_oura: a Rust toolkit for the Oura Ring (Gen 3/4/5)

0xcrypto1 pts0 comments

GitHub - Th0rgal/open_oura: A Rust toolkit for the Oura Ring (Gen 3/4/5): reverse-engineered BLE protocol, event decoders, and reimplemented data-processing algorithms. Sync, store, and analyze your data locally. · GitHub

/" data-turbo-transient="true" />

Skip to content

Search or jump to...

Search code, repositories, users, issues, pull requests...

-->

Search

Clear

Search syntax tips

Provide feedback

--><br>We read every piece of feedback, and take your input very seriously.

Include my email address so I can be contacted

Cancel

Submit feedback

Saved searches

Use saved searches to filter your results more quickly

-->

Name

Query

To see all available qualifiers, see our documentation.

Cancel

Create saved search

Sign in

/;ref_cta:Sign up;ref_loc:header logged out"}"<br>Sign up

Appearance settings

Resetting focus

You signed in with another tab or window. Reload to refresh your session.<br>You signed out in another tab or window. Reload to refresh your session.<br>You switched accounts on another tab or window. Reload to refresh your session.

Dismiss alert

{{ message }}

Th0rgal

open_oura

Public

Notifications<br>You must be signed in to change notification settings

Fork<br>51

Star<br>356

main

BranchesTags

Go to file

CodeOpen more actions menu

Folders and files<br>NameNameLast commit message<br>Last commit date<br>Latest commit

History<br>68 Commits<br>68 Commits

crates

crates

docs

docs

tools

tools

.gitignore

.gitignore

Cargo.lock

Cargo.lock

Cargo.toml

Cargo.toml

README.md

README.md

requirements.txt

requirements.txt

View all files

Repository files navigation

open_oura

Reverse-engineering the Oura ring BLE protocol, plus an independent, cloud-free<br>client that reads your data straight from the ring.

Tested live against a Ring 3 Horizon and a Ring 5 (pairing, auth, and event sync<br>confirmed on both). Designed for Ring 3/4/5, which share the same GATT layout,<br>packet framing, and authentication flow.

What you can recover

Straight from the ring, with no Oura account: device info, battery, live heart rate<br>(IBI to BPM), latest HR / SpO2, and the full history-event stream. That stream<br>carries raw PPG/IBI/temperature/motion/SpO2 samples plus the ring's on-device<br>sleep stages, activity MET levels, and HRV.

The ring itself does not emit the 0-100 Readiness / Sleep / Activity / Stress<br>scores. But those are not computed in<br>Oura's cloud either: they're computed on the phone by the native ecore<br>engine and a set of on-device PyTorch models (the same .pt we run here), then<br>uploaded; the cloud only stores and syncs them back. So they're reproducible<br>offline. The one genuine cloud-only step is workout auto-classification<br>(POST /api/activity-tagging/v2). See<br>docs/data-recovery-map.md,<br>docs/algorithms/README.md, and<br>docs/model-runners.md for what runs.

Those PyTorch models are Oura's proprietary IP and are NOT included in this<br>repo (gitignored under notes/models/). The runners reference them by path; you<br>decrypt and supply your own locally. Nothing model-related is committed or pushed.

Repository map

crates/ : the Rust client, split by concern (oura-protocol decode,<br>oura-link fetch, oura-analysis metrics, oura-store SQLite, oura-cli).<br>Start here: crates/README.md and<br>docs/architecture.md.

tools/ : Python research bench for protocol exploration. oura_protocol.py<br>(full command matrix, auth, danger-gated ops, JSONL capture) and<br>oura_realtime_listener.py.

docs/ : protocol and reverse-engineering reference (index below).

reverse/, captures/ : local-only, gitignored. The decompiled app and raw<br>captures (which may contain serials, MACs, and auth keys).

Quick start (Rust client)

cargo build --release<br>./target/release/oura scan<br>./target/release/oura --key-file key.hex info

See crates/README.md for all commands (scan, pair,<br>info, sync, latest, live-hr, accel, viz, game, features, rdata,<br>events, redecode, sleep-analyze, sessions) and the auth-key details. oura viz opens a<br>real-time 3D motion visualizer in the browser; oura game is a tilt-controlled<br>asteroid game driven by the ring.

Research bench (Python)

python3 -m venv .venv && .venv/bin/pip install -r requirements.txt<br>.venv/bin/python tools/oura_protocol.py --list

State-changing and destructive commands are hidden behind --include-state and<br>--include-danger. On macOS, grant Bluetooth permission to the terminal.

Documentation

docs/horizon-ring3-protocol-cheatsheet.md:<br>the protocol command reference (requests, responses, auth, features), Ring 3.

docs/android-app-reversing.md: app internals,<br>BLE constants, the auth operations, key generation, and nonce encryption.

docs/data-recovery-map.md: what the ring emits vs<br>what only the cloud computes.

docs/sync-orchestration.md: when and how the app<br>pulls each data channel, and the minimal client sync recipe.

docs/ring-5-observations.md: Ring 5 BLE surface<br>and first-contact findings.

docs/ring-features.md: the feature capabilities, runtime<br>modes, what's on by default, and which event each enabled feature...

ring oura docs protocol data auth

Related Articles