GoatCounter v2.7.0 Release Notes
Release Date: 2025-12-15 // 6 months ago-
2025-12-15 v2.7.0
π This release contains a number of incremental improvements and fixes. Nothing especially major.
π³ Also available on DockerHub: https://hub.docker.com/r/arp242/goatcounter
π Features
π The
-geodbflag now accepts-geodb=maxmind:account_id:licenseto automatically download updates. Seegoatcounter help servefor the full documentation.Automatically detect
secureandsameSitecookie attributes. Previously this relied on the correct usage of the-tlsflag, which people often got wrong. Now it's detected from the client connection.π WebSocket support is now detected automatically, without the need to set the
-websocketflag (which is now a no-op).Store bot pageviews in a new
botstable for 30 days. This table is never accessed, but it can be useful for debugging purposes.π§ Read the
GOATCOUNTER_TMPDIRenvironment variable as an alternative way to setTMPDIR. Mainly intended for cases whereTMPDIRcan't be used (e.g. when the capability bit is set on Linux).β‘οΈ Use PostgreSQL 17 in compose.yaml; also update the PostgreSQL settings to be less conservative.
The
-smtpflag now also supportssmtps://URLs for TLS connections (previously it only supported STARTTLS). To help with debugging you can now also add?debug=1to print SMTP traffic to stderr, or use the new Server Management β Email page for testing the SMTP connection.β Add more detailed totals to
/api/v0/stats/totals. Previously it would only return the grand totals; now it also returns the totals broken down by hour and day.Allow finding paths by name in the API. Everything that accepts
include_paths=..andexclude_paths=..now also acceptspath_by_name=trueto finds paths by the path rather than ID.π Expand filter syntax with some keywords such as
at:startandin:path. See the tooltip on the filter input.The JS-based datepicker can be disabled in the user settings.
β Add buttons to navigate by year on the dashboard.
π Fixes
π Don't add
translate-to=..to query parameters. Previously it would set this from Google Translate parameters so you could see which languages people were using with that, but I don't think anyone ever used that and it just split paths for no good reason.π Make sure CLI flags with a
.such as-user.emailcan be set from environment (asUSER_EMAIL).Adjust screen size categories for more modern devices.
API Tokens will now work for all sites the user has access to.
π Fix default
combined-vhostandcommon-vhostlog formats from$host:[..]to$host [..].Include all sites in email reports, instead of just the first site that was created.
π Fix merging of multiple paths when more than one path has entries for the same hour.
Store Campaign in hits table.
π Make sure the visitor counter works for events; previously it only worked for paths.
Set CORS headers for API.
Pass
hideui=1when redirecting with access-token.π Fix pagination of Top referrers.
π Fix page count for text table after pagination.
β Remove
sizestable; was only used forhits.size_id, which is now replaced withhits.width. This indirection didn't really add much.Correctly display error on widgets; previously it would just display
errors.errorString Value.Disable daily view if less than 7 days are selected as it just looks weird.
Previous changes from v2.6.0
-
π This release changes a number of default values. In most cases this shouldn't break anything, but be sure to read the section.
Compiling GoatCounter requires Go 1.21 or newer.
π Changes in defaults
0οΈβ£ The default values for the
-listenand-tlsflags have changed from-listen=:443 -tls=tls,rdr,acmeto-listen=:8080 -tls=none.0οΈβ£ The default SQLite database location changed from
./db/goatcounter.sqlite3to./goatcounter-data/db.sqlite3. The old file will still be used as a default if it exists, so this shouldn't break any existing setups.0οΈβ£ The default ACME secrets location changed from
./acme-secretsto./goatcounter-data/acme-secrets. The old directory will still be used as a default if it exists, so shouldn't break any existing setups.π No longer check for
window.goatcounter.varsandwindow.counterincount.js. These were changed a week or so after the initial release over five years ago. AFAIK no one is using them.0οΈβ£ No longer store individual pageviews in the
hitstable by default.
π Features
π Include Dockerfile and publish images on DockerHub. See README for details.
0οΈβ£ Take default values of CLI flags from environment variables as
GOATCOUNTER_Β«FLAGΒ», where Β«FLAGΒ» is identical to the CLI flag name. The CLI always takes precedence.Automatically load GeoIP database from
./goatcounter-data/directory if it exists; it automatically loads the first .mmdb file.π Improve log parsing:
π Improve dark theme, and enable by default if set in browser/system preferences.
β Add translations for Chinese, Korean.
β Add HTTP2 Cleartext (h2c) handler to improve compatibility with some proxies.
β Add
-base-pathflag to allow running GoatCounter under a different path such asexample.com/stats.π Allow importing Google Analytics reports. Google Analytics doesn't really offer a meaningful export, but does allow exporting "reports" with the totals per path. We can't show anything useful on the dashboard, but we can use it to show correct totals on the visitor counter.
π· Sites are no longer soft-deleted for 7 days. The deletion is still as a background job as it may take a while.
π Fixes
π Use img-based fallback if sendBeacon fails in count.js. This helps with some sites that forbid using connect-src from the CSP (e.g. neocities).
π Disable keyboard input on datepicker. Previously the arrow keys would move the date, but this was more annoying than anything else and prevented manually twiddling the text.
π Set CORS on the visitor counter (
/counter/[..].json)in case of errors. It would only setAccess-Control-Allow-Originif the operation succeeded, but not on errors so you'd never see the error.Strip trailing slash from visitor counter. Trailing slashes are always stripped for paths in the dashboard, so do it in the visitor counter as well.
π Better error if SQLite DB directory isn't writable when creating a new database. SQLite doesn't try to create the file until the first SQL command, which happens to be the version check. This would fail with a confusing
requires SQLite 3.35.0 or newer; have ""error.π Better styling when printing the dashboard.
Correctly populate the
languagestable when creating a new database. Previously collecting language statistics didn't work correct due to this.