# Confidence interval calculator

- Human page: https://happytails.ai/en/calculators/confidence-interval-calculator/
- Markdown: https://happytails.ai/en/calculators/confidence-interval-calculator.md
- Structured JSON: https://happytails.ai/agents/en/calculators/confidence-interval-calculator/index.json
- Visibility: public

## Tool capabilities

| Property | Value |
| --- | --- |
| Tool ID | `confidence-interval-calculator` |
| Category | calculators |
| Implementation | Registered implementation. Registration alone is not a production-quality guarantee. |
| Browser execution | Automatic updates after valid input or file selection. |
| Browser processing | Browser; see tool notes for network behavior. |
| HTTP API | Not callable through HTTP. |
| Browser-agent interface | run_current_tool |

### Implementation notes

Two-sided t or z intervals for a mean, or a Wilson score interval for a binomial proportion. The t method needs at least two observations. Confidence is long-run method coverage, not a probability assigned to this fixed parameter.

### Inputs and settings

No free-text input is required. Use the file inputs and/or settings below.

| Setting | Meaning | Control type | Default | Constraints |
| --- | --- | --- | --- | --- |
| `method` | Interval method | select | "Mean (sample SD)" | Allowed: Mean (sample SD), Mean (known population SD), Proportion (Wilson) |
| `confidence` | Confidence level (%) | number | 95 | min=50 max=99.99 step=any |
| `n` | Sample size | number | 30 | min=1 max=10000000 step=1 |
| `mean` | Observed mean | number | 10 | min=-1000000000000 max=1000000000000 step=any |
| `sd` | Standard deviation | number | 2 | min=0 max=1000000000000 step=any |
| `successes` | Observed successes | number | 15 | min=0 max=10000000 step=1 |

### Browser-agent workflow

1. Open the human page in a browser that supports WebMCP.
2. Discover the interface exposed by that page; use its actual schema.
3. Select files on the page first when the tool requires files.
4. Call `run_current_tool` with valid input and settings.
5. Inspect the returned result or error and the displayed output. Retrieve files from the displayed download links.

Calls do not automatically copy or download results. Browser permissions still apply. Interface availability alone is not proof of successful execution.

### Planning specification

Two-sided intervals, confidence 50–99.99%, up to ten million observations. Student t intervals require at least two observations and sample SD. The z method requires known population SD. Wilson intervals model independent binary outcomes and return proportions from 0 to 1.

This describes intended requirements. Use the implementation notes, interface schema and observed output to determine current support.

### Complete machine-readable capability record

```json
{
  "id": "confidence-interval-calculator",
  "category": "calculators",
  "built": true,
  "requirements": "Two-sided intervals, confidence 50–99.99%, up to ten million observations. Student t intervals require at least two observations and sample SD. The z method requires known population SD. Wilson intervals model independent binary outcomes and return proportions from 0 to 1.",
  "implementation": {
    "fields": [
      {
        "key": "method",
        "label": "Interval method",
        "value": "Mean (sample SD)",
        "type": "select",
        "values": [
          "Mean (sample SD)",
          "Mean (known population SD)",
          "Proportion (Wilson)"
        ]
      },
      {
        "key": "confidence",
        "label": "Confidence level (%)",
        "value": 95,
        "type": "number",
        "min": 50,
        "max": 99.99,
        "step": "any"
      },
      {
        "key": "n",
        "label": "Sample size",
        "value": 30,
        "type": "number",
        "min": 1,
        "max": 10000000,
        "step": 1
      },
      {
        "key": "mean",
        "label": "Observed mean",
        "value": 10,
        "type": "number",
        "min": -1000000000000,
        "max": 1000000000000,
        "step": "any",
        "showWhen": {
          "method": [
            "Mean (sample SD)",
            "Mean (known population SD)"
          ]
        }
      },
      {
        "key": "sd",
        "label": "Standard deviation",
        "value": 2,
        "type": "number",
        "min": 0,
        "max": 1000000000000,
        "step": "any",
        "help": "Use sample SD for the t interval, and a genuinely known population SD for the z interval.",
        "showWhen": {
          "method": [
            "Mean (sample SD)",
            "Mean (known population SD)"
          ]
        }
      },
      {
        "key": "successes",
        "label": "Observed successes",
        "value": 15,
        "type": "number",
        "min": 0,
        "max": 10000000,
        "step": 1,
        "showWhen": {
          "method": [
            "Proportion (Wilson)"
          ]
        }
      }
    ],
    "note": "Two-sided t or z intervals for a mean, or a Wilson score interval for a binomial proportion. The t method needs at least two observations. Confidence is long-run method coverage, not a probability assigned to this fixed parameter.",
    "input": false,
    "live": true,
    "presentation": "metrics",
    "background": false,
    "inputMaxLength": 1000000,
    "inputErrorCode": "STAT_SIZE",
    "experience": {
      "automatic": true,
      "single": false,
      "inputMaxLength": 1000000,
      "inputMode": "text",
      "label": "Your text",
      "placeholder": "Type or paste your input…",
      "help": "Change the input or settings to update your result. Results update as you type. Up to 1,000,000 characters.",
      "action": null
    },
    "mode": "automatic",
    "interactive": false
  },
  "execution": "Browser interface",
  "api": null,
  "browser_agent": {
    "supported": true,
    "name": "run_current_tool",
    "discovery": "WebMCP on the human page in a supporting browser",
    "verification": "See audit/API-AUDIT.md; availability is not verification"
  }
}
```

## Page guide

Calculate two-sided t, z or Wilson confidence intervals from summary statistics.

How can we improve this tool?

Report a problem or share an idea.

Please leave out private information. Your message and the tool name go to our team via PostHog.

### How to use Confidence interval calculator

1. Enter the observations or summary values.
2. Choose the method and check its assumptions.
3. Review the result and download the calculation.

## Useful next steps

- [Probability calculator](https://happytails.ai/en/calculators/probability-calculator/) ([Markdown](https://happytails.ai/en/calculators/probability-calculator.md))

- [Multiple testing correction](https://happytails.ai/en/calculators/multiple-testing-correction/) ([Markdown](https://happytails.ai/en/calculators/multiple-testing-correction.md))

## Choose the model before reading the result

Calculate two-sided t, z or Wilson confidence intervals from summary statistics.

### Check the assumptions

Two-sided intervals, confidence 50–99.99%, up to ten million observations. Student t intervals require at least two observations and sample SD. The z method requires known population SD. Wilson intervals model independent binary outcomes and return proportions from 0 to 1.

### Keep the calculation

Download the JSON for unrounded results and settings, CSV for the table, and the separate assumptions note. The calculation runs in your browser.
