Privacy Statement
AskStat is a free hobby project. You can use it without an account; logging in is optional and only adds sync between devices.
1. What is this?
AskStat is run by Hans Olav Melberg. It answers questions with data and code, and lets you write and run Python, R, DuckDB/SQL and JavaScript directly in the browser. Your scripts, the datasets you load and the run results stay in your browser by default. They leave it only in the cases described below: when you use the AI features (section 2), when you log in (section 3), when you turn on error reports (section 4), and when the app fetches libraries or data from the web, or you use GitHub, comments or sharing (section 6).
2. The AI features (Ask and the AI assistant)
The AI features use either your own API key (pasted under AI settings) or, if you are logged in, the service's own key. You choose the provider: Anthropic is the default, but you may configure an Anthropic- or OpenAI-compatible service at an address you enter yourself.
- Your key is stored only in your browser (
localStorage) and sent as a request header to our server functions on Netlify, which forward it to the provider you selected for that one request. The server does not store or log the key. - What is sent to the provider depends on the feature and may include: your question and the router's interpretation of it; earlier messages in the conversation; your profiles/preferences and selected source packs; the names and notes of your own keys (never their values); the script in the editor (when you choose to include it); and the output of code the AI runs in your browser (
run_code), which is sent back to the model so it can write the answer. Values written assecret_key="…"and the injectedKEYS = {…}line are masked in the browser before anything is sent. - Web search. When web search is on, the provider searches the web on your behalf; your question (or parts of it) is then sent to the provider's search service.
- A provider you chose yourself handles the request — and your key — under its own terms and privacy policy. We have no agreement with, and no control over, such a provider.
- No storage of content on our server. The answers are streamed straight back to your browser. Our server functions do not store questions, scripts or answers (Netlify may keep short technical logs of requests, such as time, path and status code).
- IP address and rate limiting. To prevent abuse, the server counts calls to the
/api/endpoints per IP address (for IPv6: per /64 network) and endpoint. The counters are stored in Netlify Blobs: the address is part of the key, together with the times of the calls in the last hour. Older times are removed the next time the same address makes a call, but the entry with the IP address itself is not deleted automatically. - Usage on your own key is billed to your account with the provider — we never see payment information.
Code that runs in your browser. Code written by the AI, and scripts from links shared by others, run in the app's own page. Such code can technically read what the app has stored in the browser, including your API keys and login. The app therefore asks before running a script from a shared link, and asks before running AI-written code that appears to touch browser storage. This check is a safeguard, not a sandbox: deliberately disguised code may not be detected. Only run links and code you trust.
3. Account and sync (optional, via Anvil)
Logging in is optional and only adds sync — everything else works without an account. Login and sync are provided by our own backend hosted at Anvil (mdataapi.anvil.app, Anvil Works Ltd, UK). When you log in:
- Your email address is sent to Anvil, which emails you a login code and stores your account (email and account details).
- The browser keeps a login token and, so it can show it to you again, your login code in
localStorage. Our Netlify server functions check the login token against Anvil when you use the AI features as a logged-in user. - Anvil stores, per account: your profiles; your question history (questions, generated code and metadata — not the written answers); and your API keys, encrypted in your browser with a key derived from your login code before upload, so Anvil stores only ciphertext.
- To be transparent: the login code passes through the server when you log in, so a malicious operator could technically capture it. The encryption protects against database leaks and casual inspection, not against the service itself.
"Log out" keeps your local data on the device and stops syncing. "Log out and clear this device" also removes keys, history and profiles from the browser — use it on shared computers. To delete your account and everything stored on the server, contact us (section 9).
4. Error reports (off unless you turn them on)
Error reports are off by default. If you turn them on in the AI settings, then each time an Ask answer fails, a report is sent to our Anvil backend (mdataapi.anvil.app). The report contains: your question, the AI's interpretation, the failed scripts (with stored keys masked), the error messages, which sources were tried, the app version, language, mode and type of AI provider. We use the reports to find and fix data sources that have stopped working. The settings have a "Show what would be sent" button that displays the last report built in your tab. Turning it off again stops all sending.
5. Cookies and local storage
The app sets no cookies of its own. It uses localStorage in your browser to remember settings and work: API keys, AI provider and model, login token and login code (if you log in), the encryption key for sync, GitHub token and profiles (if you connect GitHub), question history, profiles, drafts and recent scripts, mode, theme and language. A service worker stores fixed versions of program libraries (such as Pyodide, Plotly and webR) in the browser's Cache Storage for faster start-up; datasets and other user content are not stored there.
6. Third parties and other outbound traffic
We do not sell or rent out data. Depending on what you use, data is shared with:
- The AI provider you selected (Anthropic, USA, by default) — the content described in section 2.
- Netlify (USA) — hosting of the app and server functions, and the rate-limit entries in Netlify Blobs.
- Anvil (UK) — account, sync (section 3) and, if you turn them on, error reports (section 4).
In addition, the browser connects directly to these services. They see your IP address and which address is fetched, as with any website:
- Libraries from CDNs: cdn.jsdelivr.net (Pyodide, DuckDB-WASM, markdown-it, KaTeX, Tabulator, Leaflet, Brython and JavaScript libraries), cdn.plot.ly (Plotly), cdnjs.cloudflare.com (require.js for interactive widgets), www.lactame.com (ml.js in JavaScript mode), webr.r-wasm.org and repo.r-wasm.org (R mode), and pypi.org / files.pythonhosted.org (Python packages installed on demand). Maps load tiles from tile.openstreetmap.org.
- Data you load: When a script or the AI loads data from a URL (e.g. a statistics agency's API), the browser fetches it directly from that address. If the source blocks such fetches (CORS), the request instead goes through our proxy
/api/henton Netlify: the server fetches the address for you and returns the content without storing it. To be allowed to use the proxy, the browser sends your AI key or login token along to our server; the proxy does not pass that on to the data source. For data sources that require your own key (registered under AI settings), the key is sent to the proxy in a separate header, and the proxy adds it to the request to that source's host only. Neither key is stored. These calls count towards the rate limiting in section 2. - Short names and GitHub links: Opening a link with a short name looks the name up in a registry on raw.githubusercontent.com. Links to scripts or data on GitHub are fetched from GitHub.
- GitHub (api.github.com): If you connect GitHub with your own access token, the browser talks directly to GitHub's API to list, fetch and save files in the repositories you choose. The token is stored only in the browser and sent only to GitHub. Keys in scripts you save or share are masked.
- Comments (giscus / GitHub Discussions): If you open a comment thread, the app loads the giscus widget from giscus.app. Comments are stored publicly in GitHub Discussions; to write one you sign in with GitHub, under GitHub's and giscus' terms. Nothing is loaded from giscus until you open a thread.
- Share links (
#s=…) contain the script itself, compressed in the link. Anyone you give the link to can read it; keys are masked before the link is created.
7. Your rights
Without an account, we store no content about you over time; what remains on our side are the rate-limit entries with IP address and times (section 2) and, if you turned them on, error reports (section 4). With an account, Anvil stores what is listed in section 3. You can ask for access to or deletion of this data — get in touch (section 9). You may also file a complaint with the Norwegian Data Protection Authority (datatilsynet.no).
8. Changes to this statement
Changes are published on this page, with a new date at the top.
9. Contact
Data controller: Hans Olav Melberg.
Email: hans.melberg@gmail.com.