Privacy policy

Last updated

Draft: this page hasn't been reviewed yet and may change before launch. Notes marked "Needs review" are open questions for the reviewer.

codebases is a site for practicing reading code. This policy explains what information we collect, why we collect it, who else handles it, how long we keep it, and what you can do about it. It covers the codebases website and its sign-in. "We" and "us" mean whoever runs codebases, reachable at the address under Contact.

The short version

1. Using the site without an account

Every web request carries your IP address and your browser's user agent. Our host (Vercel) and, for the code shown in the editor, Cloudflare receive them, as any web server would. We use your IP address for one thing ourselves: counting how often one address searches the code, loads the leaderboard or challenges, or makes sign-in or submission requests, so automated traffic can't overload the site. Each counter holds the address, what was counted and a request count for a window of at most one hour, and is deleted after that (section 12).

Submitting an answer and revealing hints require signing in, so browsing without an account leaves no other record with us.

Learn lessons work without an account too. Checking a lesson answer, asking for a lesson hint or showing an answer sends that request to us so we can grade it, but signed out we don't record any of it. Your lesson progress stays in your browser (section 14).

2. Signing in with GitHub

GitHub is the only way to sign in. When you sign in for the first time, GitHub asks you to let codebases read your public profile and your email addresses (the read:user and user:email permissions). It doesn't give us access to your repositories, and we can't act on GitHub for you.

Our sign-in software reads your email addresses from GitHub during each sign-in, as part of the standard GitHub sign-in flow. We don't store them. Your sign-in record holds a placeholder made from your GitHub account ID instead, and the only email address we keep is one you give us yourself (section 7).

From GitHub we store:

3. Your puzzle activity

When you submit an answer while signed in, we store:

From these we show your progress, your activity calendar and streaks, and your history. Grading is automatic: your selection is compared with the puzzle's answer key. Your submissions also decide your points, achievements and challenge completions (section 4), by fixed rules that are the same for everyone. These results only change what the site shows. We don't use your activity to profile you or to make any other decision about you.

4. Hints, points, challenges and achievements

While you're signed in, we also record:

Puzzles you solved before we started recording hints were given points from your submission history, with no hint deduction. None of this is shown to anyone but you unless you join the leaderboard, and even then only your totals are (section 6).

5. Learn lesson progress

When you're signed in and answer one of a lesson's required checks correctly, we record which lesson, which version of it, which of its required checks you've answered correctly, and when you finished it. That's all. We don't record wrong answers, the hints you ask for, the answers you choose to show, or what you write in the capstone's explanation box, which never leaves your browser. Learn progress isn't shown to anyone else, and it doesn't affect points, challenges or the leaderboard.

Progress you made while signed out stays in that browser and isn't copied into your account when you sign in.

6. The leaderboard

The leaderboard is opt-in and off by default: nobody appears on it until they choose to. To join, open Settings, go to Leaderboard visibility, and choose a public name (2 to 30 letters, numbers, spaces and . _ - '). It's separate from your display name and your GitHub username, so it reveals neither unless you type it in. Each public name can be used by only one account, ignoring capitals.

Anyone can see the leaderboard, signed in or not. For each person who joined and has points in the period shown (all time, today, this week or this month), it shows:

Your totals include points you earned before you joined. The leaderboard never shows your GitHub username, display name, email address, picture, account ID, submissions, answers, hints, achievements or profile. To run it, we store your public name and when you joined.

You can rename yourself or leave at any time in Settings, under Leaderboard visibility. Leaving deletes your entry and public name immediately, and you disappear from every period's leaderboard at once. Your points stay on your account, visible only to you, so if you join again later your totals come back. While signed in, you see your own points and standing even when you haven't joined; no one else does. People who viewed the leaderboard while you were on it may still remember or have copied what it showed. We may remove a public name that breaks the terms.

7. Your contact email

To finish setting up an account, we ask for an email address. You can keep using the site before you add one. We confirm the address by emailing a link that works once, only for the account that asked for it, and only for 30 minutes.

We use your confirmed address only to reach you about your account:

We don't send newsletters, marketing, or reminders about streaks or challenges, we don't show your address to anyone, and you still sign in only with GitHub. Changing a confirmed address requires a sign-in within the last 15 minutes.

For each link we send, we keep the address it was for and a fingerprint (SHA-256 hash) of the link, never the link itself, so a stolen copy of our database can't be used to confirm an address. Section 12 says how long these records stay.

8. Details you choose to add

Everything in this section is optional, can be changed or removed in Settings at any time, and is shown only to you:

None of these appear on the leaderboard. Please don't put information in these fields that you wouldn't want stored, such as health information or anything about other people.

9. Sign-in sessions and security records

10. What we don't do

11. Why we use your data

If you're in the European Economic Area, the UK or Switzerland, these are the legal bases we rely on:

12. How long we keep it

DataKept until
Account, GitHub identity and encrypted tokenYou delete your account.
Learn progressYou delete your account.
Submissions, progress and historyYou delete your account.
Hint reveals, points, challenge completions and achievementsYou delete your account. Leaving the leaderboard doesn't remove them.
Leaderboard entry and public nameYou leave the leaderboard or delete your account. Either removes them immediately.
Confirmed contact emailYou replace it with a newly confirmed one, or delete your account.
Pending address and link fingerprintThe link stops working after 30 minutes or once used. A pending record is removed when you confirm an address or request another link. The record of a link that was used stays until you delete your account.
Profile details, links, picture, theme choicesYou remove them in Settings, or delete your account.
Session recordsRemoved when you sign out of that session. A session you don't sign out of stops working 7 days after it was last refreshed (it's refreshed at most once a day while you use the site), and its record can stay until you delete your account.
Sign-in checksStop working after 10 minutes. Removed when used, and expired ones are removed at the next sign-in.
Rate-limit countersEach counts for at most an hour. Cleanup that runs as the site is used deletes counters more than an hour old, so one can stay a little longer when the site is quiet. Your account's counters go at once when you delete it.
Host request and error logs, provider backups, emails already sentEach provider's own retention schedule (section 13).
Messages you send to our contact addressKept in that mailbox until we delete them.

13. Who else handles your data

These service providers process data for us to run the site. Each may use it only to provide its service to us, under its own privacy terms:

ProviderWhat it doesWhat it handles
VercelHosts the website and its serverEvery request, including IP address and user agent; short-lived request and error logs
SupabaseHosts our databaseAll the account data described above
CloudflareStores and serves the source files shown in the editorIP address, user agent and which file was requested
GitHubHandles sign-inThat you signed in to codebases, under GitHub's own privacy statement
Google (Gmail)Sends our emailsThe recipient address and the message, including any confirmation link

We may also disclose data if the law requires it, or to protect the site or its users from fraud, abuse or attack. If codebases is ever transferred to someone else, this policy would continue to apply to the data transferred, and we would say so on this page first.

These providers are based in the United States and may process data there or in other countries. Where data protection law requires it, we rely on the providers' standard contractual clauses or equivalent safeguards for these transfers.

14. Cookies and browser storage

We use only what the site needs to work, so there's no cookie banner. None of these are used for tracking or advertising.

NamePurposeLasts
better-auth.state (cookie)Ties GitHub's reply to the sign-in you started5 minutes, set only when you start signing in
better-auth.session_token (cookie)Keeps you signed inUntil you sign out, or 7 days after its last refresh
cb-theme (local storage)Remembers the colors of your current theme so pages show it before they finish loadingUntil you clear your browser's site data
cb-theme-guest, cb-theme-favorites (local storage)Your theme choice and favorites while signed out. They stay in your browser and aren't sent to usUntil you clear your browser's site data
cb-learn-progress (local storage)Your Learn progress while signed out: which lessons and checks you've completed in this browser. It stays in your browser and isn't sent to usUntil you clear your browser's site data
cb-signed-in (local storage)Remembers that someone has signed in on this browser, so the home page offers To puzzles instead of sign-in. It holds only the value 1, isn't sent to us, and is cleared when you sign out or delete your accountUntil you clear your browser's site data
cp-dev-login (local storage)A random name, such as dev-3f2a, for the sign-in developers use when they run the site on their own computer. This site may store it, but never uses it or sends it to usUntil you clear your browser's site data
cp_dev_login (cookie)That same developer sign-in. Only a copy of the site running on a developer's own computer sets it30 days

Over HTTPS, the sign-in cookie names start with __Secure-. Both are first-party, unreadable by page scripts, and sent only to codebases. Signing out deletes the session cookie and its session record, and deleting your account clears it too. Because we don't track you, there's nothing for a browser's Do Not Track or Global Privacy Control signal to turn off.

15. How we protect it

No system is perfectly secure. If a breach affects your personal data, we'll tell you at your confirmed contact email, and the authorities where the law requires it, without undue delay.

16. Your choices and rights

These controls are yours to use at any time:

To make a request, write to the address under Contact. We may ask you to confirm the request from your confirmed contact email or while signed in, so we know it's you. We'll answer within 30 days. If you're not satisfied, you can also complain to your local data protection authority.

17. Deleting your account

In Settings, under Danger zone, choose Delete account and type DELETE (in capitals) to confirm. For your security, deleting needs a GitHub sign-in within the last 15 minutes; if yours is older, you'll be asked to sign in with GitHub again first. Deleting immediately and permanently removes:

It also removes the records of the email links we sent you and your account's rate-limit counters, and signs you out. It all happens in one step, and it can't be undone. You disappear from the leaderboard at once.

Deleting your codebases account doesn't delete your GitHub account, and it doesn't remove codebases from the apps you've authorized on GitHub. To do that, revoke access in GitHub as section 16 describes. Copies in our providers' logs and backups aren't reachable by us and expire on their own schedules (section 12). Emails we already sent stay in your inbox.

18. Children

codebases isn't meant for children under 13, and GitHub's terms don't allow them to have an account. If you believe a child under 13 has signed in, write to us and we'll delete the account.

19. Changes to this policy

When what we collect or how we use it changes, we update this page and the date at the top before the change takes effect. If a change means we'd use data you've already given us in a materially different way, we'll also tell you by email or on the site, and ask for your consent where the law requires it.

20. Contact

For questions about your data or this policy, or to make a request, write to mailcodebases@gmail.com.