You’re debugging a production issue. You remember a test failed with the same error three months ago. You go to find that test report… and it’s gone. The CI artifacts expired. Sound familiar?
Why CI Providers Delete Your Test Artifacts
Every major CI/CD platform automatically deletes artifacts after a retention period:
| CI Provider | Default Retention | Max Retention |
|---|---|---|
| GitHub Actions | 90 days | 400 days (paid) |
| GitLab CI | 30 days | Configurable |
| CircleCI | 30 days | 30 days |
| Azure DevOps | 30 days | Configurable |
| Bitbucket Pipelines | 14 days | 14 days |
Why do they do this? Storage costs money. CI providers optimize for build speed and compute, not long-term artifact storage. Your test reports are considered disposable.
The Real Cost of Expiring Artifacts
Losing test artifacts isn’t just annoying—it has real consequences:
1. Debugging Becomes Harder
When a bug resurfaces, historical test data is invaluable. Which tests were failing before we “fixed” this? What did the error message say? Without the original artifacts, you’re starting from scratch.
2. Flaky Test Analysis is Impossible
To understand flaky tests, you need data across many runs. If artifacts expire after 30 days, you lose the historical context needed to identify patterns.
3. Compliance Requirements
Regulated industries (finance, healthcare, automotive) often require test evidence retention for years. CI artifact expiration violates these requirements.
4. Onboarding Suffers
New team members can’t see how the test suite evolved. They can’t reference past failures to understand why certain tests exist.
5. Post-Mortems Lack Evidence
“What went wrong?” is hard to answer when the test reports from the incident are gone.
Workarounds (and Why They Fall Short)
Increase CI Retention
Some CI providers let you extend retention. GitHub Actions goes up to 400 days with paid plans. But:
- Still not permanent
- Expensive at scale (GitHub charges for storage)
- Doesn’t solve the access problem (finding artifacts is still tedious)
Upload to S3/GCS
You can add a CI step to upload artifacts to your own cloud storage:
- name: Upload to S3
run: aws s3 cp ./test-results s3://my-bucket/reports/${{ github.sha }} --recursiveProblems:
- Manual setup and maintenance
- No built-in access control
- No UI for browsing reports
- Still need to manage storage costs and cleanup
Save Locally
Some teams download important artifacts before they expire. This doesn’t scale and relies on someone remembering to do it.
The Real Solution: Dedicated Test Report Hosting
Instead of fighting CI artifact limits, host your test reports on a platform designed for it:
- Automatic upload from CI pipeline
- Configurable retention per project (up to 90 days on paid plans)
- Instant access via shareable URLs
- Team-based permissions tied to your organization
- Search and analytics across all historical runs
How Gaffer Solves CI Artifact Expiration
Gaffer is purpose-built for test report hosting. Here’s how it works:
Step 1: Add One Line to CI
GitHub Actions:
- name: Upload to Gaffer
if: always()
uses: gaffer-sh/gaffer-uploader@v2
with:
api-key: ${{ secrets.GAFFER_UPLOAD_TOKEN }}
report-path: ./test-resultsAny CI with curl:
curl -X POST https://api.gaffer.sh/upload \
-H "X-API-Key: $GAFFER_UPLOAD_TOKEN" \
-F "files=@test-results/report.html" \
-F "branch=$CI_BRANCH" \
-F "commit=$CI_COMMIT_SHA"Step 2: Choose Your Retention
Every upload gets a shareable URL. You control how long reports are kept:
| Plan | Default Retention | Per-Project Settings |
|---|---|---|
| Free | 7 days | Custom retention periods |
| Pro | 30 days | Custom retention periods |
| Team | 90 days | Custom retention periods |
Longer retention than CI providers - Keep test data for up to 90 days with Team plans, plenty of time for debugging and analysis.
Want to keep costs low? Enable automatic cleanup and set a shorter retention period. Test reports from feature branches might only need 7 days, while production test data could be kept longer.
Step 3: Access Anytime
- Browse reports in the Gaffer dashboard
- Search by branch, commit, date range
- Share links with teammates
- Get Slack notifications with direct links
Per-Project Retention Control
Different projects have different needs. Gaffer lets you configure retention per-project:
- Production tests: Keep for 90 days (Team plan)
- Feature branch tests: Auto-delete after 7 days
- Important projects: Use longer retention periods
All plans can set custom retention periods to match your needs.
Beyond Storage: Analytics Over Time
When you keep test data longer, you unlock insights that short CI retention makes difficult:
- Pass rate trends - Is the suite getting more stable?
- Flaky test detection - Which tests fail intermittently?
- Regression detection - When did this test start failing?
- Duration trends - Are tests getting slower?
Migration Path
Already have test reports scattered across CI providers? Gaffer works alongside your existing setup:
- Add Gaffer upload to CI (takes 5 minutes)
- New reports go to Gaffer automatically
- Old reports in CI continue to expire (nothing changes)
- Over time, Gaffer becomes your source of truth
No migration, no data import, just better going forward.
Get Started
Stop losing test artifacts. Gaffer gives you control over retention with per-project settings and longer retention periods than most CI providers offer.