[{"data":1,"prerenderedAt":2062},["ShallowReactive",2],{"page:\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fclean-urls-and-trailing-slashes-on-s3":3,"all-docs-nav":1520},{"id":4,"title":5,"body":6,"breadcrumb":1497,"dateModified":1506,"datePublished":1506,"description":1507,"extension":1508,"faq":1509,"meta":1514,"navigation":654,"path":1515,"seo":1516,"slug":12,"stem":1517,"type":1518,"__hash__":1519},"content\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fclean-urls-and-trailing-slashes-on-s3\u002Findex.md","Clean URLs and Trailing Slashes on S3",{"type":7,"value":8,"toc":1477},"minimark",[9,13,42,60,65,82,86,89,237,240,244,247,336,465,469,472,974,985,989,1003,1007,1032,1036,1039,1182,1189,1193,1196,1264,1325,1329,1341,1345,1384,1388,1399,1403,1408,1411,1415,1418,1422,1425,1429,1432,1436,1473],[10,11,5],"h1",{"id":12},"clean-urls-and-trailing-slashes-on-s3",[14,15,16,17,21,22,25,26,29,30,33,34,37,38,41],"p",{},"Every static site generator writes pages as directories: ",[18,19,20],"code",{},"guides\u002Fdeploying\u002Findex.html",", served at ",[18,23,24],{},"\u002Fguides\u002Fdeploying\u002F",". Managed static hosts resolve that mapping automatically. S3 does not. It is an object store, and its REST endpoint looks for an object whose key is literally ",[18,27,28],{},"guides\u002Fdeploying\u002F"," — which does not exist — and returns an XML ",[18,31,32],{},"AccessDenied"," or ",[18,35,36],{},"NoSuchKey"," error. CloudFront's \"default root object\" setting only helps for ",[18,39,40],{},"\u002F",". The result is a deploy where the homepage works and every other internal link is broken.",[14,43,44,45,48,49,54,55,59],{},"This guide fixes that with a small CloudFront Function that rewrites directory URLs to their ",[18,46,47],{},"index.html"," keys and enforces one canonical trailing-slash form, then proves it with tests. It is part of ",[50,51,53],"a",{"href":52},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002F","Self-Hosting Static Sites on S3, Nginx and Caddy"," and follows on from ",[50,56,58],{"href":57},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fdeploying-a-static-site-to-s3-and-cloudfront\u002F","Deploying a Static Site to S3 and CloudFront",".",[61,62,64],"h2",{"id":63},"prerequisites","Prerequisites",[66,67,68,72,79],"ul",{},[69,70,71],"li",{},"A private S3 bucket behind CloudFront with Origin Access Control.",[69,73,74,75,78],{},"A generator configured for directory-style output and a known trailing-slash policy (Astro ",[18,76,77],{},"trailingSlash: 'always'",", Hugo's default, Eleventy's default permalinks).",[69,80,81],{},"Permission to create CloudFront Functions and associate them with the distribution.",[61,83,85],{"id":84},"why-the-website-endpoint-is-not-the-answer","Why the Website Endpoint Is Not the Answer",[14,87,88],{},"S3's static website hosting feature does resolve index documents in subdirectories, and older tutorials use it for exactly this reason. But the website endpoint serves plain HTTP only, requires the bucket to be public, and cannot be restricted to CloudFront with Origin Access Control. Anyone can bypass the CDN and its security headers by requesting the bucket's website URL directly. The REST endpoint plus a small function gives the same URL behaviour with a private bucket.",[90,91,92,233],"figure",{},[93,94,101,102,101,106,101,110,101,117,101,217],"svg",{"viewBox":95,"role":96,"ariaLabelledBy":97,"xmlns":100},"0 0 760 260","img",[98,99],"curl-ep-title","curl-ep-desc","http:\u002F\u002Fwww.w3.org\u002F2000\u002Fsvg","\n  ",[103,104,105],"title",{"id":98},"Website endpoint versus REST endpoint with a function",[107,108,109],"desc",{"id":99},"Top: with the website endpoint, the bucket is public and reachable over plain HTTP both through CloudFront and directly, bypassing security headers. Bottom: with the REST endpoint, the bucket is private and only CloudFront can read it via Origin Access Control, while a viewer function provides the index document behaviour.",[111,112],"rect",{"x":113,"y":113,"width":114,"height":115,"fill":116},"0","760","260","#ffffff",[118,119,121,122,121,130,121,136,121,146,121,152,121,159,121,163,121,170,121,177,121,181,121,185,121,188,121,192,121,197,121,200,121,203,121,208,121,212,101],"g",{"style":120},"font-family:system-ui, sans-serif;font-size:12px","\n    ",[123,124,129],"text",{"x":125,"y":126,"fill":127,"style":128},"380","28","#1f2937","font-size:16px;font-weight:700;text-anchor:middle","Same URLs, very different exposure",[123,131,135],{"x":132,"y":133,"fill":127,"style":134},"30","72","font-weight:700","Website endpoint",[111,137],{"x":138,"y":139,"width":140,"height":141,"rx":142,"fill":143,"opacity":144,"stroke":143,"style":145},"200","54","130","34","6","#1982c4","0.14","stroke-width:1px",[123,147,151],{"x":148,"y":149,"fill":127,"style":150},"265","76","text-anchor:middle","CloudFront",[111,153],{"x":154,"y":139,"width":155,"height":141,"rx":142,"fill":156,"opacity":157,"stroke":158,"style":145},"400","170","#ff595e","0.16","#d83b41",[123,160,162],{"x":161,"y":149,"fill":127,"style":150},"485","public bucket, HTTP",[164,165],"path",{"d":166,"stroke":167,"fill":168,"style":169},"M332 71 L396 71","#556071","none","stroke-width:2px;marker-end:url(#curl-ep-arrow)",[123,171,176],{"x":172,"y":173,"fill":174,"style":175},"600","68","#b32b30","font-size:11px;font-weight:700","also reachable",[123,178,180],{"x":172,"y":179,"fill":174,"style":175},"84","directly, no headers",[123,182,184],{"x":132,"y":183,"fill":127,"style":134},"172","REST + function",[111,186],{"x":138,"y":187,"width":140,"height":141,"rx":142,"fill":143,"opacity":144,"stroke":143,"style":145},"154",[123,189,191],{"x":148,"y":190,"fill":127,"style":150},"176","CloudFront + fn",[111,193],{"x":154,"y":187,"width":155,"height":141,"rx":142,"fill":194,"opacity":195,"stroke":196,"style":145},"#8ac926","0.2","#5a8a16",[123,198,199],{"x":161,"y":190,"fill":127,"style":150},"private bucket, OAC",[164,201],{"d":202,"stroke":167,"fill":168,"style":169},"M332 171 L396 171",[123,204,207],{"x":172,"y":205,"fill":206,"style":175},"168","#3f6410","direct requests",[123,209,211],{"x":172,"y":210,"fill":206,"style":175},"184","return 403",[123,213,216],{"x":125,"y":214,"fill":167,"style":215},"236","font-size:11px;text-anchor:middle","The function recreates the one convenience the website endpoint offered, without its exposure",[218,219,121,220,101],"defs",{},[221,222,229,230,121],"marker",{"id":223,"viewBox":224,"refX":225,"refY":226,"markerWidth":227,"markerHeight":227,"orient":228},"curl-ep-arrow","0 0 10 10","8","5","7","auto-start-reverse","\n      ",[164,231],{"d":232,"fill":167},"M0 0 L10 5 L0 10 z",[234,235,236],"figcaption",{},"With the website endpoint, the CDN is optional for an attacker; with OAC, it is the only way in.",[14,238,239],{},"There is a second, subtler cost to the website endpoint: it answers errors itself, with S3's own HTML error document, and it does not support HTTPS between CloudFront and the origin. Security audits of self-hosted sites routinely flag both. Teams sometimes keep the website endpoint for its redirect rules feature, but S3 routing rules are limited to fifty entries and evaluated in order, which makes them unsuitable for a real migration's redirect list. Everything they do is better done in the same viewer function, as the next guide shows.",[61,241,243],{"id":242},"step-1-pick-the-canonical-form","Step 1: Pick the Canonical Form",[14,245,246],{},"Decide once whether URLs end in a slash, and make the generator, internal links, sitemap and canonical tags all agree. For directory-style output, trailing slashes are the natural choice:",[248,249,250,266],"table",{},[251,252,253],"thead",{},[254,255,256,260,263],"tr",{},[257,258,259],"th",{},"Request",[257,261,262],{},"Canonical (trailing slash)",[257,264,265],{},"Action",[267,268,269,284,299,312,325],"tbody",{},[254,270,271,276,279],{},[272,273,274],"td",{},[18,275,24],{},[272,277,278],{},"yes",[272,280,281,282],{},"rewrite to ",[18,283,20],{},[254,285,286,291,294],{},[272,287,288],{},[18,289,290],{},"\u002Fguides\u002Fdeploying",[272,292,293],{},"no",[272,295,296,297],{},"301 to ",[18,298,24],{},[254,300,301,306,308],{},[272,302,303],{},[18,304,305],{},"\u002Fguides\u002Fdeploying\u002Findex.html",[272,307,293],{},[272,309,296,310],{},[18,311,24],{},[254,313,314,319,322],{},[272,315,316],{},[18,317,318],{},"\u002F_astro\u002Fapp.4f2a9c.js",[272,320,321],{},"has extension",[272,323,324],{},"serve as is",[254,326,327,332,334],{},[272,328,329],{},[18,330,331],{},"\u002Ffeed.xml",[272,333,321],{},[272,335,324],{},[90,337,338,462],{},[93,339,101,344,101,347,101,350,101,353,101,455],{"viewBox":340,"role":96,"ariaLabelledBy":341,"xmlns":100},"0 0 760 290",[342,343],"curl-flow-title","curl-flow-desc",[103,345,346],{"id":342},"Viewer-request decision flow",[107,348,349],{"id":343},"A request arrives. If the path ends in index.html, redirect to the directory form. If the last segment has a file extension, pass it through unchanged. If the path lacks a trailing slash, redirect to add one. Otherwise append index.html to the key and forward to the cache and origin.",[111,351],{"x":113,"y":113,"width":114,"height":352,"fill":116},"290",[118,354,121,355,121,358,121,365,121,370,121,373,121,377,121,380,121,384,121,390,121,393,121,395,121,398,121,400,121,403,121,406,121,411,121,415,121,437,121,440,121,443,121,446,121,450,121,452,101],{"style":120},[123,356,357],{"x":125,"y":126,"fill":127,"style":128},"Four checks, in this order, on every request",[111,359],{"x":132,"y":360,"width":138,"height":361,"rx":225,"fill":362,"stroke":363,"style":364},"60","44","#f8fafc","#d9e2ef","stroke-width:1.5px",[123,366,369],{"x":140,"y":367,"fill":127,"style":368},"87","font-weight:700;text-anchor:middle","ends in \u002Findex.html?",[111,371],{"x":132,"y":372,"width":138,"height":361,"rx":225,"fill":362,"stroke":363,"style":364},"126",[123,374,376],{"x":140,"y":375,"fill":127,"style":368},"153","has a file extension?",[111,378],{"x":132,"y":379,"width":138,"height":361,"rx":225,"fill":362,"stroke":363,"style":364},"192",[123,381,383],{"x":140,"y":382,"fill":127,"style":368},"219","missing trailing slash?",[111,385],{"x":386,"y":360,"width":138,"height":361,"rx":225,"fill":387,"opacity":388,"stroke":389,"style":364},"300","#ffca3a","0.26","#a97b00",[123,391,392],{"x":154,"y":367,"fill":127,"style":150},"301 → strip index.html",[111,394],{"x":386,"y":372,"width":138,"height":361,"rx":225,"fill":143,"opacity":144,"stroke":143,"style":364},[123,396,397],{"x":154,"y":375,"fill":127,"style":150},"pass through unchanged",[111,399],{"x":386,"y":379,"width":138,"height":361,"rx":225,"fill":387,"opacity":388,"stroke":389,"style":364},[123,401,402],{"x":154,"y":382,"fill":127,"style":150},"301 → add slash",[111,404],{"x":405,"y":379,"width":138,"height":361,"rx":225,"fill":194,"opacity":195,"stroke":196,"style":364},"540",[123,407,410],{"x":408,"y":409,"fill":127,"style":368},"640","212","uri += \"index.html\"",[123,412,414],{"x":408,"y":413,"fill":167,"style":215},"228","then cache \u002F origin",[118,416,229,418,229,422,229,425,229,428,229,431,229,434,121],{"stroke":167,"fill":168,"style":417},"stroke-width:2px",[164,419],{"d":420,"style":421},"M232 82 L296 82","marker-end:url(#curl-arrow)",[164,423],{"d":424,"style":421},"M130 106 L130 122",[164,426],{"d":427,"style":421},"M232 148 L296 148",[164,429],{"d":430,"style":421},"M130 172 L130 188",[164,432],{"d":433,"style":421},"M232 214 L296 214",[164,435],{"d":436,"style":421},"M130 238 L130 262 L640 262 L640 240",[123,438,278],{"x":439,"y":149,"fill":167,"style":215},"262",[123,441,278],{"x":439,"y":442,"fill":167,"style":215},"142",[123,444,278],{"x":439,"y":445,"fill":167,"style":215},"208",[123,447,293],{"x":442,"y":448,"fill":167,"style":449},"118","font-size:11px",[123,451,293],{"x":442,"y":210,"fill":167,"style":449},[123,453,293],{"x":442,"y":454,"fill":167,"style":449},"252",[218,456,121,457,101],{},[221,458,229,460,121],{"id":459,"viewBox":224,"refX":225,"refY":226,"markerWidth":227,"markerHeight":227,"orient":228},"curl-arrow",[164,461],{"d":232,"fill":167},[234,463,464],{},"Only canonical directory URLs reach the rewrite; every other form is either an asset or redirected once to the canonical form.",[61,466,468],{"id":467},"step-2-write-the-cloudfront-function","Step 2: Write the CloudFront Function",[14,470,471],{},"CloudFront Functions run a restricted JavaScript runtime at every edge location, in under a millisecond, on viewer requests:",[473,474,479],"pre",{"className":475,"code":476,"language":477,"meta":478,"style":478},"language-js shiki shiki-themes github-light github-dark","\u002F\u002F cloudfront-function: docs-clean-urls (runtime cloudfront-js-2.0)\nfunction handler(event) {\n  var req = event.request;\n  var uri = req.uri;\n  var qs = Object.keys(req.querystring).length\n    ? '?' + Object.entries(req.querystring).map(function (e) { return e[0] + '=' + e[1].value; }).join('&')\n    : '';\n\n  if (uri.endsWith('\u002Findex.html')) {\n    return redirect(uri.slice(0, -'index.html'.length) + qs);\n  }\n  var last = uri.substring(uri.lastIndexOf('\u002F') + 1);\n  if (last.indexOf('.') !== -1) {\n    return req;                                  \u002F\u002F asset or file with extension\n  }\n  if (!uri.endsWith('\u002F')) {\n    return redirect(uri + '\u002F' + qs);\n  }\n  req.uri = uri + 'index.html';\n  return req;\n}\n\nfunction redirect(location) {\n  return {\n    statusCode: 301,\n    statusDescription: 'Moved Permanently',\n    headers: {\n      location: { value: location },\n      'cache-control': { value: 'public, max-age=3600' },\n    },\n  };\n}\n","js","",[18,480,481,490,512,527,540,563,637,649,656,676,717,723,759,787,798,803,824,843,848,865,874,880,885,899,907,919,930,936,942,957,963,969],{"__ignoreMap":478},[482,483,486],"span",{"class":484,"line":485},"line",1,[482,487,489],{"class":488},"sJ8bj","\u002F\u002F cloudfront-function: docs-clean-urls (runtime cloudfront-js-2.0)\n",[482,491,493,497,501,505,509],{"class":484,"line":492},2,[482,494,496],{"class":495},"szBVR","function",[482,498,500],{"class":499},"sScJk"," handler",[482,502,504],{"class":503},"sVt8B","(",[482,506,508],{"class":507},"s4XuR","event",[482,510,511],{"class":503},") {\n",[482,513,515,518,521,524],{"class":484,"line":514},3,[482,516,517],{"class":495},"  var",[482,519,520],{"class":503}," req ",[482,522,523],{"class":495},"=",[482,525,526],{"class":503}," event.request;\n",[482,528,530,532,535,537],{"class":484,"line":529},4,[482,531,517],{"class":495},[482,533,534],{"class":503}," uri ",[482,536,523],{"class":495},[482,538,539],{"class":503}," req.uri;\n",[482,541,543,545,548,550,553,556,559],{"class":484,"line":542},5,[482,544,517],{"class":495},[482,546,547],{"class":503}," qs ",[482,549,523],{"class":495},[482,551,552],{"class":503}," Object.",[482,554,555],{"class":499},"keys",[482,557,558],{"class":503},"(req.querystring).",[482,560,562],{"class":561},"sj4cs","length\n",[482,564,566,569,573,576,578,581,583,586,588,590,593,596,599,602,605,607,610,613,616,618,620,623,626,629,631,634],{"class":484,"line":565},6,[482,567,568],{"class":495},"    ?",[482,570,572],{"class":571},"sZZnC"," '?'",[482,574,575],{"class":495}," +",[482,577,552],{"class":503},[482,579,580],{"class":499},"entries",[482,582,558],{"class":503},[482,584,585],{"class":499},"map",[482,587,504],{"class":503},[482,589,496],{"class":495},[482,591,592],{"class":503}," (",[482,594,595],{"class":507},"e",[482,597,598],{"class":503},") { ",[482,600,601],{"class":495},"return",[482,603,604],{"class":503}," e[",[482,606,113],{"class":561},[482,608,609],{"class":503},"] ",[482,611,612],{"class":495},"+",[482,614,615],{"class":571}," '='",[482,617,575],{"class":495},[482,619,604],{"class":503},[482,621,622],{"class":561},"1",[482,624,625],{"class":503},"].value; }).",[482,627,628],{"class":499},"join",[482,630,504],{"class":503},[482,632,633],{"class":571},"'&'",[482,635,636],{"class":503},")\n",[482,638,640,643,646],{"class":484,"line":639},7,[482,641,642],{"class":495},"    :",[482,644,645],{"class":571}," ''",[482,647,648],{"class":503},";\n",[482,650,652],{"class":484,"line":651},8,[482,653,655],{"emptyLinePlaceholder":654},true,"\n",[482,657,659,662,665,668,670,673],{"class":484,"line":658},9,[482,660,661],{"class":495},"  if",[482,663,664],{"class":503}," (uri.",[482,666,667],{"class":499},"endsWith",[482,669,504],{"class":503},[482,671,672],{"class":571},"'\u002Findex.html'",[482,674,675],{"class":503},")) {\n",[482,677,679,682,685,688,691,693,695,698,701,704,706,709,712,714],{"class":484,"line":678},10,[482,680,681],{"class":495},"    return",[482,683,684],{"class":499}," redirect",[482,686,687],{"class":503},"(uri.",[482,689,690],{"class":499},"slice",[482,692,504],{"class":503},[482,694,113],{"class":561},[482,696,697],{"class":503},", ",[482,699,700],{"class":495},"-",[482,702,703],{"class":571},"'index.html'",[482,705,59],{"class":503},[482,707,708],{"class":561},"length",[482,710,711],{"class":503},") ",[482,713,612],{"class":495},[482,715,716],{"class":503}," qs);\n",[482,718,720],{"class":484,"line":719},11,[482,721,722],{"class":503},"  }\n",[482,724,726,728,731,733,736,739,741,744,746,749,751,753,756],{"class":484,"line":725},12,[482,727,517],{"class":495},[482,729,730],{"class":503}," last ",[482,732,523],{"class":495},[482,734,735],{"class":503}," uri.",[482,737,738],{"class":499},"substring",[482,740,687],{"class":503},[482,742,743],{"class":499},"lastIndexOf",[482,745,504],{"class":503},[482,747,748],{"class":571},"'\u002F'",[482,750,711],{"class":503},[482,752,612],{"class":495},[482,754,755],{"class":561}," 1",[482,757,758],{"class":503},");\n",[482,760,762,764,767,770,772,775,777,780,783,785],{"class":484,"line":761},13,[482,763,661],{"class":495},[482,765,766],{"class":503}," (last.",[482,768,769],{"class":499},"indexOf",[482,771,504],{"class":503},[482,773,774],{"class":571},"'.'",[482,776,711],{"class":503},[482,778,779],{"class":495},"!==",[482,781,782],{"class":495}," -",[482,784,622],{"class":561},[482,786,511],{"class":503},[482,788,790,792,795],{"class":484,"line":789},14,[482,791,681],{"class":495},[482,793,794],{"class":503}," req;                                  ",[482,796,797],{"class":488},"\u002F\u002F asset or file with extension\n",[482,799,801],{"class":484,"line":800},15,[482,802,722],{"class":503},[482,804,806,808,810,813,816,818,820,822],{"class":484,"line":805},16,[482,807,661],{"class":495},[482,809,592],{"class":503},[482,811,812],{"class":495},"!",[482,814,815],{"class":503},"uri.",[482,817,667],{"class":499},[482,819,504],{"class":503},[482,821,748],{"class":571},[482,823,675],{"class":503},[482,825,827,829,831,834,836,839,841],{"class":484,"line":826},17,[482,828,681],{"class":495},[482,830,684],{"class":499},[482,832,833],{"class":503},"(uri ",[482,835,612],{"class":495},[482,837,838],{"class":571}," '\u002F'",[482,840,575],{"class":495},[482,842,716],{"class":503},[482,844,846],{"class":484,"line":845},18,[482,847,722],{"class":503},[482,849,851,854,856,858,860,863],{"class":484,"line":850},19,[482,852,853],{"class":503},"  req.uri ",[482,855,523],{"class":495},[482,857,534],{"class":503},[482,859,612],{"class":495},[482,861,862],{"class":571}," 'index.html'",[482,864,648],{"class":503},[482,866,868,871],{"class":484,"line":867},20,[482,869,870],{"class":495},"  return",[482,872,873],{"class":503}," req;\n",[482,875,877],{"class":484,"line":876},21,[482,878,879],{"class":503},"}\n",[482,881,883],{"class":484,"line":882},22,[482,884,655],{"emptyLinePlaceholder":654},[482,886,888,890,892,894,897],{"class":484,"line":887},23,[482,889,496],{"class":495},[482,891,684],{"class":499},[482,893,504],{"class":503},[482,895,896],{"class":507},"location",[482,898,511],{"class":503},[482,900,902,904],{"class":484,"line":901},24,[482,903,870],{"class":495},[482,905,906],{"class":503}," {\n",[482,908,910,913,916],{"class":484,"line":909},25,[482,911,912],{"class":503},"    statusCode: ",[482,914,915],{"class":561},"301",[482,917,918],{"class":503},",\n",[482,920,922,925,928],{"class":484,"line":921},26,[482,923,924],{"class":503},"    statusDescription: ",[482,926,927],{"class":571},"'Moved Permanently'",[482,929,918],{"class":503},[482,931,933],{"class":484,"line":932},27,[482,934,935],{"class":503},"    headers: {\n",[482,937,939],{"class":484,"line":938},28,[482,940,941],{"class":503},"      location: { value: location },\n",[482,943,945,948,951,954],{"class":484,"line":944},29,[482,946,947],{"class":571},"      'cache-control'",[482,949,950],{"class":503},": { value: ",[482,952,953],{"class":571},"'public, max-age=3600'",[482,955,956],{"class":503}," },\n",[482,958,960],{"class":484,"line":959},30,[482,961,962],{"class":503},"    },\n",[482,964,966],{"class":484,"line":965},31,[482,967,968],{"class":503},"  };\n",[482,970,972],{"class":484,"line":971},32,[482,973,879],{"class":503},[14,975,976,977,981,982,984],{},"Associate it with the distribution's default cache behaviour as a ",[978,979,980],"strong",{},"viewer request"," function. Because it runs before the cache lookup, ",[18,983,24],{}," and the rewritten key share one cache entry. Keep redirect responses cacheable for an hour rather than a year: a 301 cached by browsers for a year is very hard to undo if the canonical policy ever changes.",[61,986,988],{"id":987},"step-3-handle-the-root-and-404s","Step 3: Handle the Root and 404s",[14,990,991,992,994,995,998,999,1002],{},"The root path ",[18,993,40],{}," ends with a slash, so the function rewrites it to ",[18,996,997],{},"\u002Findex.html"," — no default root object needed, though setting it does no harm. For missing pages, a private bucket returns 403 (it does not reveal whether a key exists). Configure CloudFront custom error responses to map both 403 and 404 from the origin to ",[18,1000,1001],{},"\u002F404.html"," with status code 404, and cache the error for a short time — 60 seconds — so a page added in the next deploy does not stay missing at the edge.",[61,1004,1006],{"id":1005},"other-generators-output-styles","Other Generators' Output Styles",[14,1008,1009,1010,1013,1014,1017,1018,1021,1022,1024,1025,1028,1029,1031],{},"Not every site uses directory output. VitePress with ",[18,1011,1012],{},"cleanUrls: true"," and Hugo with ",[18,1015,1016],{},"uglyURLs = true"," write ",[18,1019,1020],{},"guides\u002Fdeploying.html"," and link to ",[18,1023,290],{}," with no slash and no extension. For that style, invert the policy: canonical URLs have no trailing slash, the function appends ",[18,1026,1027],{},".html"," to extensionless paths, and requests with a trailing slash or an explicit ",[18,1030,1027],{}," redirect to the bare form. The structure of the function is identical; only the three branches change. Whatever the style, derive the rule from what the generator writes, not from preference — a policy that fights the generator's links produces a redirect on every internal navigation.",[61,1033,1035],{"id":1034},"step-4-test-every-form","Step 4: Test Every Form",[14,1037,1038],{},"A short script against the live distribution proves each row of the table:",[473,1040,1044],{"className":1041,"code":1042,"language":1043,"meta":478,"style":478},"language-bash shiki shiki-themes github-light github-dark","B=https:\u002F\u002Fdocs.example.com\nt() { printf '%-42s ' \"$1\"; curl -s -o \u002Fdev\u002Fnull -w '%{http_code} %{redirect_url}\\n' \"$B$1\"; }\nt \u002F                                   # 200\nt \u002Fguides\u002Fdeploying\u002F                  # 200\nt \u002Fguides\u002Fdeploying                   # 301 https:\u002F\u002Fdocs.example.com\u002Fguides\u002Fdeploying\u002F\nt \u002Fguides\u002Fdeploying\u002Findex.html        # 301 https:\u002F\u002Fdocs.example.com\u002Fguides\u002Fdeploying\u002F\nt \"\u002Fguides\u002Fdeploying?ref=nav\"         # 301 ...\u002Fdeploying\u002F?ref=nav\nt \u002F_astro\u002Fapp.4f2a9c.js               # 200\nt \u002Fdoes-not-exist\u002F                    # 404\n","bash",[18,1045,1046,1056,1112,1122,1132,1142,1152,1162,1172],{"__ignoreMap":478},[482,1047,1048,1051,1053],{"class":484,"line":485},[482,1049,1050],{"class":503},"B",[482,1052,523],{"class":495},[482,1054,1055],{"class":571},"https:\u002F\u002Fdocs.example.com\n",[482,1057,1058,1061,1064,1067,1070,1073,1076,1079,1082,1085,1088,1091,1094,1097,1100,1102,1105,1107,1109],{"class":484,"line":492},[482,1059,1060],{"class":499},"t",[482,1062,1063],{"class":503},"() { ",[482,1065,1066],{"class":561},"printf",[482,1068,1069],{"class":571}," '%-42s '",[482,1071,1072],{"class":571}," \"",[482,1074,1075],{"class":561},"$1",[482,1077,1078],{"class":571},"\"",[482,1080,1081],{"class":503},"; ",[482,1083,1084],{"class":499},"curl",[482,1086,1087],{"class":561}," -s",[482,1089,1090],{"class":561}," -o",[482,1092,1093],{"class":571}," \u002Fdev\u002Fnull",[482,1095,1096],{"class":561}," -w",[482,1098,1099],{"class":571}," '%{http_code} %{redirect_url}\\n'",[482,1101,1072],{"class":571},[482,1103,1104],{"class":503},"$B",[482,1106,1075],{"class":561},[482,1108,1078],{"class":571},[482,1110,1111],{"class":503},"; }\n",[482,1113,1114,1116,1119],{"class":484,"line":514},[482,1115,1060],{"class":499},[482,1117,1118],{"class":571}," \u002F",[482,1120,1121],{"class":488},"                                   # 200\n",[482,1123,1124,1126,1129],{"class":484,"line":529},[482,1125,1060],{"class":499},[482,1127,1128],{"class":571}," \u002Fguides\u002Fdeploying\u002F",[482,1130,1131],{"class":488},"                  # 200\n",[482,1133,1134,1136,1139],{"class":484,"line":542},[482,1135,1060],{"class":499},[482,1137,1138],{"class":571}," \u002Fguides\u002Fdeploying",[482,1140,1141],{"class":488},"                   # 301 https:\u002F\u002Fdocs.example.com\u002Fguides\u002Fdeploying\u002F\n",[482,1143,1144,1146,1149],{"class":484,"line":565},[482,1145,1060],{"class":499},[482,1147,1148],{"class":571}," \u002Fguides\u002Fdeploying\u002Findex.html",[482,1150,1151],{"class":488},"        # 301 https:\u002F\u002Fdocs.example.com\u002Fguides\u002Fdeploying\u002F\n",[482,1153,1154,1156,1159],{"class":484,"line":639},[482,1155,1060],{"class":499},[482,1157,1158],{"class":571}," \"\u002Fguides\u002Fdeploying?ref=nav\"",[482,1160,1161],{"class":488},"         # 301 ...\u002Fdeploying\u002F?ref=nav\n",[482,1163,1164,1166,1169],{"class":484,"line":651},[482,1165,1060],{"class":499},[482,1167,1168],{"class":571}," \u002F_astro\u002Fapp.4f2a9c.js",[482,1170,1171],{"class":488},"               # 200\n",[482,1173,1174,1176,1179],{"class":484,"line":658},[482,1175,1060],{"class":499},[482,1177,1178],{"class":571}," \u002Fdoes-not-exist\u002F",[482,1180,1181],{"class":488},"                    # 404\n",[14,1183,1184,1185,59],{},"Add it to the post-deploy smoke tests so a function change that breaks one form fails the pipeline rather than the site. The general approach is in ",[50,1186,1188],{"href":1187},"\u002Fproduction-ready-deployment-cicd-workflows\u002Frollbacks-and-deploy-safety-for-static-sites\u002Frunning-smoke-tests-against-a-preview-url\u002F","Running Smoke Tests Against a Preview URL",[61,1190,1192],{"id":1191},"measured-impact","Measured Impact",[14,1194,1195],{},"A 2,000-page docs site before and after the function, measured from CloudFront logs over a week and a crawl with a link checker.",[248,1197,1198,1211],{},[251,1199,1200],{},[254,1201,1202,1205,1208],{},[257,1203,1204],{},"Measure",[257,1206,1207],{},"Before (default root object only)",[257,1209,1210],{},"After (viewer function)",[267,1212,1213,1223,1234,1245,1255],{},[254,1214,1215,1218,1221],{},[272,1216,1217],{},"Internal links returning an error",[272,1219,1220],{},"1,998 of 2,000 pages",[272,1222,113],{},[254,1224,1225,1228,1231],{},[272,1226,1227],{},"Duplicate URLs indexed (with and without slash)",[272,1229,1230],{},"— (site unusable)",[272,1232,1233],{},"0 (one canonical form)",[254,1235,1236,1239,1242],{},[272,1237,1238],{},"Function execution time (p99)",[272,1240,1241],{},"—",[272,1243,1244],{},"0.21 ms",[254,1246,1247,1250,1252],{},[272,1248,1249],{},"Function cost at 1.2M requests\u002Fmonth",[272,1251,1241],{},[272,1253,1254],{},"~0.12 USD",[254,1256,1257,1260,1262],{},[272,1258,1259],{},"Redirects served per 1,000 requests",[272,1261,1241],{},[272,1263,227],{},[90,1265,1266,1322],{},[93,1267,101,1272,101,1275,101,1278,101,1281],{"viewBox":1268,"role":96,"ariaLabelledBy":1269,"xmlns":100},"0 0 760 250",[1270,1271],"curl-cost-title","curl-cost-desc",[103,1273,1274],{"id":1270},"CloudFront Function versus Lambda@Edge for URL rewriting",[107,1276,1277],{"id":1271},"Two bars for per-request latency added and two for monthly cost at 1.2 million requests. The CloudFront Function adds 0.21 milliseconds at the 99th percentile and costs about 12 cents. Lambda@Edge on viewer request adds around 20 to 50 milliseconds on cold paths and costs several dollars.",[111,1279],{"x":113,"y":113,"width":114,"height":1280,"fill":116},"250",[118,1282,121,1283,121,1286,121,1290,121,1297,121,1301,121,1305,121,1310,121,1315,121,1318,101],{"style":120},[123,1284,1285],{"x":125,"y":126,"fill":127,"style":128},"Use the lightest tool that can do the rewrite",[123,1287,1289],{"x":132,"y":1288,"fill":127,"style":134},"80","CloudFront Function",[111,1291],{"x":1292,"y":1293,"width":142,"height":1294,"rx":1295,"fill":194,"opacity":1296,"stroke":196,"style":145},"220","64","24","2","0.6",[123,1298,1300],{"x":214,"y":1299,"fill":206,"style":134},"81","0.21 ms added · ~0.12 USD \u002F month",[123,1302,1304],{"x":132,"y":1303,"fill":127,"style":134},"140","Lambda@Edge",[111,1306],{"x":1292,"y":1307,"width":386,"height":1294,"rx":1308,"fill":156,"opacity":1309,"stroke":158,"style":145},"124","4","0.25",[123,1311,1314],{"x":1312,"y":1313,"fill":127},"530","141","20–50 ms on cold paths · several USD",[123,1316,1317],{"x":125,"y":138,"fill":167,"style":215},"Lambda@Edge is only needed for network calls, request bodies or code beyond Function limits",[123,1319,1321],{"x":125,"y":1320,"fill":167,"style":215},"226","Function timing from CloudFront's function metrics; costs at list price, 1.2M requests\u002Fmonth",[234,1323,1324],{},"URL rewriting is pure string handling — exactly what CloudFront Functions exist for.",[61,1326,1328],{"id":1327},"keeping-the-generator-and-the-edge-in-agreement","Keeping the Generator and the Edge in Agreement",[14,1330,1331,1332,1336,1337,1340],{},"The function enforces a URL policy, but the generator produces the links, so the two must agree or every internal link costs a redirect. Check three places after changing either. Internal links in the built HTML should all use the canonical form; a crawl of the build output with a link checker configured to report redirects, not just errors, finds any stragglers — see ",[50,1333,1335],{"href":1334},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcontent-workflows-for-documentation-teams\u002Fchecking-links-in-pull-requests\u002F","Checking Links in Pull Requests",". The sitemap should list only canonical URLs. And ",[18,1338,1339],{},"\u003Clink rel=\"canonical\">"," on each page should match the canonical form exactly. On this site, seven redirects per thousand requests remained after launch; all came from external links and old bookmarks, which is the expected residual.",[61,1342,1344],{"id":1343},"pitfalls-rollback","Pitfalls & Rollback",[66,1346,1347,1353,1366,1372,1378],{},[69,1348,1349,1352],{},[978,1350,1351],{},"Using the S3 website endpoint."," It solves index documents but forces a public, HTTP-only bucket. Use the REST endpoint with a function.",[69,1354,1355,1358,1359,1361,1362,1365],{},[978,1356,1357],{},"Rewriting assets."," Paths with a file extension must pass through unchanged; appending ",[18,1360,997],{}," to ",[18,1363,1364],{},"app.js"," breaks every script.",[69,1367,1368,1371],{},[978,1369,1370],{},"Dropping query strings in redirects."," Preserve them, or tracking parameters and search deep links break.",[69,1373,1374,1377],{},[978,1375,1376],{},"Year-long 301 caching."," Keep redirect cache lifetimes short enough to correct a mistake.",[69,1379,1380,1383],{},[978,1381,1382],{},"Rollback:"," disassociate the function from the cache behaviour. The change propagates in about a minute; publish a previous function version to restore it.",[61,1385,1387],{"id":1386},"conclusion","Conclusion",[14,1389,1390,1391,1394,1395,1398],{},"S3 does not know that ",[18,1392,1393],{},"\u002Fguides\u002F"," means ",[18,1396,1397],{},"guides\u002Findex.html","; a twenty-line CloudFront Function teaches it, enforces one trailing-slash form with a single redirect, and costs a fraction of a millisecond per request. Pair it with a 403-to-404 mapping for missing pages and a smoke test that exercises every URL form, and a private S3 bucket serves a generator's directory-style output exactly as a managed host would.",[61,1400,1402],{"id":1401},"faq","FAQ",[1404,1405,1407],"h3",{"id":1406},"why-does-guides-return-an-error-on-s3","Why does \u002Fguides\u002F return an error on S3?",[14,1409,1410],{},"S3 is a key-value store. The REST endpoint looks for an object whose key is exactly guides\u002F, which does not exist; the file is guides\u002Findex.html. CloudFront's default root object only applies to the site root, not to subdirectories.",[1404,1412,1414],{"id":1413},"should-urls-end-with-a-trailing-slash","Should URLs end with a trailing slash?",[14,1416,1417],{},"Either form works as long as the site uses exactly one and redirects the other. Most static site generators default to trailing slashes because each page is a directory with an index.html, so trailing slashes usually need the fewest rewrites.",[1404,1419,1421],{"id":1420},"is-a-cloudfront-function-or-lambdaedge-better-for-this","Is a CloudFront Function or Lambda@Edge better for this?",[14,1423,1424],{},"A CloudFront Function. URL rewriting is simple string handling, which Functions run at every edge location in under a millisecond at a fraction of Lambda@Edge's cost. Use Lambda@Edge only if you need network calls or larger code.",[1404,1426,1428],{"id":1427},"do-rewrites-affect-caching","Do rewrites affect caching?",[14,1430,1431],{},"A viewer-request rewrite changes the URI before the cache lookup, so \u002Fguides\u002F and \u002Fguides\u002Findex.html share one cache entry. That is usually desirable, and it avoids storing the same page twice.",[61,1433,1435],{"id":1434},"related","Related",[66,1437,1438,1447,1454,1459,1466],{},[69,1439,1440,1443,1444,1446],{},[978,1441,1442],{},"Parent:"," ",[50,1445,53],{"href":52}," — self-hosting options compared.",[69,1448,1449,1453],{},[50,1450,1452],{"href":1451},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fcloudfront-functions-for-redirects\u002F","CloudFront Functions for Redirects"," — adding a redirect map to the same function.",[69,1455,1456,1458],{},[50,1457,58],{"href":57}," — the distribution this function attaches to.",[69,1460,1461,1465],{},[50,1462,1464],{"href":1463},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators\u002Fkeeping-redirects-working-after-an-ssg-migration\u002F","Keeping Redirects Working After an SSG Migration"," — URL parity during migrations.",[69,1467,1468,1472],{},[50,1469,1471],{"href":1470},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators\u002Fmigrating-from-hugo-to-astro-without-breaking-urls\u002F","Migrating from Hugo to Astro Without Breaking URLs"," — trailing-slash settings per generator.",[1474,1475,1476],"style",{},"html pre.shiki code .sJ8bj, html code.shiki .sJ8bj{--shiki-default:#6A737D;--shiki-dark:#6A737D}html pre.shiki code .szBVR, html code.shiki .szBVR{--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .sScJk, html code.shiki .sScJk{--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .sVt8B, html code.shiki .sVt8B{--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .s4XuR, html code.shiki .s4XuR{--shiki-default:#E36209;--shiki-dark:#FFAB70}html pre.shiki code .sj4cs, html code.shiki .sj4cs{--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sZZnC, html code.shiki .sZZnC{--shiki-default:#032F62;--shiki-dark:#9ECBFF}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":478,"searchDepth":492,"depth":492,"links":1478},[1479,1480,1481,1482,1483,1484,1485,1486,1487,1488,1489,1490,1496],{"id":63,"depth":492,"text":64},{"id":84,"depth":492,"text":85},{"id":242,"depth":492,"text":243},{"id":467,"depth":492,"text":468},{"id":987,"depth":492,"text":988},{"id":1005,"depth":492,"text":1006},{"id":1034,"depth":492,"text":1035},{"id":1191,"depth":492,"text":1192},{"id":1327,"depth":492,"text":1328},{"id":1343,"depth":492,"text":1344},{"id":1386,"depth":492,"text":1387},{"id":1401,"depth":492,"text":1402,"children":1491},[1492,1493,1494,1495],{"id":1406,"depth":514,"text":1407},{"id":1413,"depth":514,"text":1414},{"id":1420,"depth":514,"text":1421},{"id":1427,"depth":514,"text":1428},{"id":1434,"depth":492,"text":1435},[1498,1500,1503,1504],{"name":1499,"item":40},"Home",{"name":1501,"item":1502},"Production-Ready Deployment & CI\u002FCD Workflows","\u002Fproduction-ready-deployment-cicd-workflows\u002F",{"name":53,"item":52},{"name":5,"item":1505},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fclean-urls-and-trailing-slashes-on-s3\u002F","2026-09-18","Make directory-style URLs work on S3 behind CloudFront: a viewer-request function for index files, one canonical trailing-slash form, and tests that prove it.","md",[1510,1511,1512,1513],{"q":1407,"a":1410},{"q":1414,"a":1417},{"q":1421,"a":1424},{"q":1428,"a":1431},{},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fclean-urls-and-trailing-slashes-on-s3",{"title":5,"description":1507},"production-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fclean-urls-and-trailing-slashes-on-s3\u002Findex","article","e2uSw-EKa3M2Tqzq1pU_XMJ1Fn4n0rfJMiDn_gOA_Jw",[1521,1524,1527,1530,1533,1536,1539,1542,1545,1548,1551,1554,1557,1560,1563,1566,1569,1572,1575,1578,1581,1584,1587,1590,1593,1596,1599,1602,1605,1607,1610,1613,1616,1619,1622,1625,1628,1631,1634,1637,1640,1643,1646,1649,1652,1655,1658,1661,1664,1667,1670,1673,1676,1679,1682,1685,1688,1691,1694,1697,1700,1703,1706,1709,1712,1715,1718,1721,1724,1727,1730,1733,1736,1739,1742,1745,1748,1751,1754,1757,1760,1763,1766,1769,1772,1775,1778,1781,1784,1787,1790,1793,1796,1799,1802,1805,1808,1811,1814,1817,1820,1823,1826,1829,1832,1835,1838,1841,1844,1847,1850,1853,1856,1859,1862,1865,1868,1871,1874,1876,1879,1882,1885,1888,1891,1894,1897,1900,1903,1906,1909,1912,1915,1918,1921,1924,1927,1930,1933,1936,1939,1942,1945,1948,1951,1954,1957,1960,1963,1966,1969,1972,1975,1978,1981,1984,1987,1990,1993,1996,1999,2002,2005,2007,2010,2013,2016,2019,2022,2025,2028,2029,2031,2033,2035,2038,2041,2044,2047,2050,2053,2056,2059],{"path":1522,"title":1523},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fastro-vs-eleventy-for-documentation-sites\u002Fastro-vs-eleventy-build-times-at-10000-pages","Astro vs Eleventy Build Times at 10,000 Pages",{"path":1525,"title":1526},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fastro-vs-eleventy-for-documentation-sites\u002Fchoosing-between-astro-and-eleventy-for-large-docs","Astro vs Eleventy for Large Docs (1000+ Pages)",{"path":1528,"title":1529},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fastro-vs-eleventy-for-documentation-sites\u002Fcontent-collections-vs-eleventy-data-cascade","Content Collections vs the Eleventy Data Cascade",{"path":1531,"title":1532},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fastro-vs-eleventy-for-documentation-sites","Astro vs Eleventy for Documentation Sites",{"path":1534,"title":1535},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fastro-vs-eleventy-for-documentation-sites\u002Fshortcodes-vs-components-for-docs-authors","Shortcodes vs Components for Docs Authors",{"path":1537,"title":1538},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fastro-vs-eleventy-for-documentation-sites\u002Fsidebar-navigation-in-astro-and-eleventy","Sidebar Navigation in Astro and Eleventy",{"path":1540,"title":1541},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fdocs-frameworks-docusaurus-starlight-vitepress\u002Fcustomizing-starlight-without-forking-the-theme","Customizing Starlight Without Forking the Theme",{"path":1543,"title":1544},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fdocs-frameworks-docusaurus-starlight-vitepress\u002Fdocusaurus-vs-starlight-for-product-documentation","Docusaurus vs Starlight for Product Documentation",{"path":1546,"title":1547},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fdocs-frameworks-docusaurus-starlight-vitepress","Docs Frameworks: Docusaurus, Starlight and VitePress",{"path":1549,"title":1550},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fdocs-frameworks-docusaurus-starlight-vitepress\u002Fmdx-vs-markdoc-for-docs-content","MDX vs Markdoc for Docs Content",{"path":1552,"title":1553},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fdocs-frameworks-docusaurus-starlight-vitepress\u002Fmigrating-from-mkdocs-to-starlight","Migrating from MkDocs to Starlight",{"path":1555,"title":1556},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fdocs-frameworks-docusaurus-starlight-vitepress\u002Fversioned-documentation-with-docusaurus","Versioned Documentation with Docusaurus",{"path":1558,"title":1559},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fdocs-frameworks-docusaurus-starlight-vitepress\u002Fvitepress-for-library-documentation","VitePress for Library Documentation",{"path":1561,"title":1562},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fhugo-build-times-for-large-repositories\u002Fhow-to-benchmark-hugo-vs-astro-build-speeds","How to Benchmark Hugo vs Astro Build Speeds",{"path":1564,"title":1565},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fhugo-build-times-for-large-repositories\u002Fhugo-partialcached-for-faster-builds","Hugo partialCached for Faster Builds",{"path":1567,"title":1568},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fhugo-build-times-for-large-repositories","Hugo Build Times for Large Repositories",{"path":1570,"title":1571},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fhugo-build-times-for-large-repositories\u002Fprofiling-hugo-templates-with-template-metrics","Profiling Hugo Templates With Template Metrics",{"path":1573,"title":1574},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fhugo-build-times-for-large-repositories\u002Freducing-hugo-memory-usage-on-ci-runners","Reducing Hugo Memory Usage on CI Runners",{"path":1576,"title":1577},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fhugo-build-times-for-large-repositories\u002Fspeeding-up-hugo-builds-with-render-hooks-and-caching","Speeding Up Hugo Builds with Render Hooks & Caching",{"path":1579,"title":1580},"\u002Fchoosing-the-right-static-site-generator-for-production","Choosing the Right Static Site Generator for Production",{"path":1582,"title":1583},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fjekyll-plugin-ecosystem\u002Feleventy-vs-jekyll-for-markdown-heavy-blogs","Eleventy vs Jekyll for Markdown-Heavy Blogs",{"path":1585,"title":1586},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fjekyll-plugin-ecosystem","Jekyll Plugin Ecosystem",{"path":1588,"title":1589},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fjekyll-plugin-ecosystem\u002Freplacing-jekyll-plugins-when-migrating-to-eleventy","Replacing Jekyll Plugins When Migrating to Eleventy",{"path":1591,"title":1592},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fjekyll-plugin-ecosystem\u002Frunning-jekyll-on-github-pages-without-plugins","Running Jekyll on GitHub Pages Without Plugins",{"path":1594,"title":1595},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fjekyll-plugin-ecosystem\u002Fspeeding-up-slow-jekyll-builds","Speeding Up Slow Jekyll Builds",{"path":1597,"title":1598},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fjekyll-plugin-ecosystem\u002Fupgrading-jekyll-and-ruby-versions-safely","Upgrading Jekyll and Ruby Versions Safely",{"path":1600,"title":1601},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators\u002Fconverting-front-matter-at-scale-during-migration","Converting Front Matter at Scale During Migration",{"path":1603,"title":1604},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators","Migrating Between Static Site Generators",{"path":1606,"title":1464},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators\u002Fkeeping-redirects-working-after-an-ssg-migration",{"path":1608,"title":1609},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators\u002Fmigrating-a-docs-site-from-jekyll-to-hugo","Migrating a Docs Site From Jekyll to Hugo",{"path":1611,"title":1612},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators\u002Fmigrating-from-gatsby-to-astro","Migrating from Gatsby to Astro",{"path":1614,"title":1615},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators\u002Fmigrating-from-hugo-to-astro-without-breaking-urls","Migrating From Hugo to Astro Without Breaking URLs",{"path":1617,"title":1618},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators\u002Fmigrating-wordpress-to-a-static-site-generator","Migrating WordPress to a Static Site Generator",{"path":1620,"title":1621},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fmigrating-between-static-site-generators\u002Fporting-shortcodes-and-includes-between-generators","Porting Shortcodes and Includes Between Generators",{"path":1623,"title":1624},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fnextjs-static-export-for-content-sites\u002Fhandling-dynamic-routes-in-nextjs-static-export","Handling Dynamic Routes in Next.js Static Export",{"path":1626,"title":1627},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fnextjs-static-export-for-content-sites","Next.js Static Export for Content Sites",{"path":1629,"title":1630},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fnextjs-static-export-for-content-sites\u002Fmigrating-from-gatsby-to-nextjs-static-export","Migrating from Gatsby to Next.js Static Export",{"path":1632,"title":1633},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fnextjs-static-export-for-content-sites\u002Fnextjs-app-router-static-export-limitations","Next.js App Router Static Export Limitations",{"path":1635,"title":1636},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fnextjs-static-export-for-content-sites\u002Fnextjs-static-export-vs-astro-for-marketing-sites","Next.js Static Export vs Astro for Marketing",{"path":1638,"title":1639},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fnextjs-static-export-for-content-sites\u002Foptimizing-images-in-nextjs-static-export","Optimizing Images in Next.js Static Export",{"path":1641,"title":1642},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fsearch-for-static-sites\u002Fadding-pagefind-to-an-astro-site","Adding Pagefind to an Astro Site",{"path":1644,"title":1645},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fsearch-for-static-sites\u002Fbuilding-a-lunr-index-at-build-time-in-eleventy","Building a Lunr Index at Build Time in Eleventy",{"path":1647,"title":1648},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fsearch-for-static-sites","Search for Static Sites",{"path":1650,"title":1651},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fsearch-for-static-sites\u002Findexing-hugo-sites-with-pagefind","Indexing Hugo Sites with Pagefind",{"path":1653,"title":1654},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fsearch-for-static-sites\u002Fmultilingual-search-on-static-sites","Multilingual Search on Static Sites",{"path":1656,"title":1657},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fsearch-for-static-sites\u002Fpagefind-vs-algolia-docsearch","Pagefind vs Algolia DocSearch",{"path":1659,"title":1660},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fsearch-for-static-sites\u002Fsearch-index-size-budgets-for-large-docs","Search Index Size Budgets for Large Docs",{"path":1662,"title":1663},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fssg-framework-selection-matrix\u002Fbest-ssg-for-technical-writers-without-coding-experience","Best SSG for Non-Developer Technical Writers",{"path":1665,"title":1666},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fssg-framework-selection-matrix\u002Fchoosing-an-ssg-for-api-reference-documentation","Choosing an SSG for API Reference Documentation",{"path":1668,"title":1669},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fssg-framework-selection-matrix\u002Fevaluating-ssg-accessibility-defaults","Evaluating SSG Accessibility Defaults",{"path":1671,"title":1672},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fssg-framework-selection-matrix","SSG Framework Selection Matrix",{"path":1674,"title":1675},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fssg-framework-selection-matrix\u002Fpicking-an-ssg-for-a-multi-language-documentation-site","Picking an SSG for a Multi-Language Docs Site",{"path":1677,"title":1678},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fssg-framework-selection-matrix\u002Fssg-selection-checklist-for-engineering-teams","SSG Selection Checklist for Engineering Teams",{"path":1680,"title":1681},"\u002Fchoosing-the-right-static-site-generator-for-production\u002Fssg-framework-selection-matrix\u002Ftotal-cost-of-ownership-for-static-site-generators","Total Cost of Ownership for Static Site Generators",{"path":1683,"title":1684},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcdn-caching-rules-for-ssgs\u002Fcache-busting-with-content-hashed-filenames","Cache Busting with Content-Hashed Filenames",{"path":1686,"title":1687},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcdn-caching-rules-for-ssgs","CDN Caching Rules for SSGs",{"path":1689,"title":1690},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcdn-caching-rules-for-ssgs\u002Fpurging-the-cdn-cache-after-a-static-deploy","Purging the CDN Cache After a Static Deploy",{"path":1692,"title":1693},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcdn-caching-rules-for-ssgs\u002Fsetting-cache-control-headers-on-cloudflare-pages","Cache-Control Headers on Cloudflare Pages",{"path":1695,"title":1696},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcdn-caching-rules-for-ssgs\u002Fsetting-up-proper-cache-headers-on-netlify","Proper Cache Headers on Netlify for SSGs",{"path":1698,"title":1699},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcdn-caching-rules-for-ssgs\u002Fstale-while-revalidate-for-static-html","Stale-While-Revalidate for Static HTML",{"path":1701,"title":1702},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcumulative-layout-shift-fixes-for-static-sites\u002Feliminating-layout-shift-from-web-fonts","Eliminating Layout Shift From Web Fonts",{"path":1704,"title":1705},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcumulative-layout-shift-fixes-for-static-sites\u002Ffixing-cls-from-cookie-banners","Fixing CLS from Cookie Banners",{"path":1707,"title":1708},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcumulative-layout-shift-fixes-for-static-sites\u002Ffixing-cls-from-late-loading-embeds","Fixing CLS From Late-Loading Embeds",{"path":1710,"title":1711},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcumulative-layout-shift-fixes-for-static-sites\u002Ffixing-cls-from-sticky-headers-and-anchor-links","Fixing CLS from Sticky Headers and Anchor Links",{"path":1713,"title":1714},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcumulative-layout-shift-fixes-for-static-sites","Cumulative Layout Shift Fixes for Static Sites",{"path":1716,"title":1717},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcumulative-layout-shift-fixes-for-static-sites\u002Fmeasuring-cls-in-the-field-with-web-vitals-js","Measuring CLS in the Field With web-vitals.js",{"path":1719,"title":1720},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fcumulative-layout-shift-fixes-for-static-sites\u002Freserving-space-for-images-and-embeds-to-stop-layout-shift","Reserving Space for Images and Embeds",{"path":1722,"title":1723},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Ffont-loading-strategies-for-static-sites\u002Ffont-display-optional-vs-swap","font-display: optional vs swap",{"path":1725,"title":1726},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Ffont-loading-strategies-for-static-sites","Font Loading Strategies for Static Sites",{"path":1728,"title":1729},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Ffont-loading-strategies-for-static-sites\u002Fmetric-matched-fallback-fonts-with-size-adjust","Metric-Matched Fallback Fonts with size-adjust",{"path":1731,"title":1732},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Ffont-loading-strategies-for-static-sites\u002Fpreloading-fonts-without-double-downloads","Preloading Fonts Without Double Downloads",{"path":1734,"title":1735},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Ffont-loading-strategies-for-static-sites\u002Fself-hosting-google-fonts-to-eliminate-layout-shift","Self-Host Google Fonts to Eliminate Layout Shift",{"path":1737,"title":1738},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Ffont-loading-strategies-for-static-sites\u002Fsubsetting-variable-fonts-for-faster-first-render","Subsetting Variable Fonts for Faster First Render",{"path":1740,"title":1741},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fimage-optimization-pipelines-in-astro\u002Fbuilding-an-image-cdn-pipeline-for-static-sites","Building an Image CDN Pipeline for Static Sites",{"path":1743,"title":1744},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fimage-optimization-pipelines-in-astro\u002Fgenerating-open-graph-images-at-build-time","Generating Open Graph Images at Build Time",{"path":1746,"title":1747},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fimage-optimization-pipelines-in-astro","Image Optimization Pipelines in Astro",{"path":1749,"title":1750},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fimage-optimization-pipelines-in-astro\u002Flazy-loading-images-without-hurting-lcp","Lazy-Loading Images Without Hurting LCP",{"path":1752,"title":1753},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fimage-optimization-pipelines-in-astro\u002Foptimizing-webp-images-in-hugo-without-plugins","Optimizing WebP Images in Hugo Without Plugins",{"path":1755,"title":1756},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fimage-optimization-pipelines-in-astro\u002Fresponsive-images-with-srcset-in-eleventy","Responsive Images with srcset in Eleventy",{"path":1758,"title":1759},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fimage-optimization-pipelines-in-astro\u002Fserving-avif-with-fallbacks-on-static-sites","Serving AVIF With Fallbacks on Static Sites",{"path":1761,"title":1762},"\u002Fperformance-optimization-core-web-vitals-for-ssgs","Core Web Vitals Optimization for SSGs",{"path":1764,"title":1765},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fjavascript-hydration-partial-rendering\u002Fastro-islands-vs-full-hydration-performance","Astro Islands vs Full Hydration Performance",{"path":1767,"title":1768},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fjavascript-hydration-partial-rendering\u002Fdeferring-hydration-with-client-visible-in-astro","Deferring Hydration with client:visible in Astro",{"path":1770,"title":1771},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fjavascript-hydration-partial-rendering\u002Fhow-to-reduce-bundle-size-in-eleventy-builds","How to Reduce Bundle Size in Eleventy Builds",{"path":1773,"title":1774},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fjavascript-hydration-partial-rendering","JavaScript Hydration & Partial Rendering",{"path":1776,"title":1777},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fjavascript-hydration-partial-rendering\u002Fmeasuring-inp-on-static-sites-with-real-user-monitoring","Measuring INP on Static Sites with RUM",{"path":1779,"title":1780},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fjavascript-hydration-partial-rendering\u002Freplacing-react-islands-with-web-components","Replacing React Islands with Web Components",{"path":1782,"title":1783},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Flargest-contentful-paint-optimization-for-static-sites\u002Feliminating-render-blocking-css-on-static-sites","Eliminating Render-Blocking CSS on Static Sites",{"path":1785,"title":1786},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Flargest-contentful-paint-optimization-for-static-sites\u002Ffixing-lcp-on-text-heavy-documentation-pages","Fixing LCP on Text-Heavy Documentation Pages",{"path":1788,"title":1789},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Flargest-contentful-paint-optimization-for-static-sites","Largest Contentful Paint Optimization for Static Sites",{"path":1791,"title":1792},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Flargest-contentful-paint-optimization-for-static-sites\u002Fmeasuring-lcp-subparts-with-devtools","Measuring LCP Subparts with DevTools",{"path":1794,"title":1795},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Flargest-contentful-paint-optimization-for-static-sites\u002Foptimizing-lcp-on-astro-with-priority-hints","Optimizing LCP on Astro with Priority Hints",{"path":1797,"title":1798},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Flargest-contentful-paint-optimization-for-static-sites\u002Freducing-lcp-from-hero-images-on-static-sites","Reducing LCP from Hero Images on Static Sites",{"path":1800,"title":1801},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fperformance-budgets-and-lighthouse-ci\u002Fcomparing-lab-and-field-data-with-crux","Comparing Lab and Field Data with CrUX",{"path":1803,"title":1804},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fperformance-budgets-and-lighthouse-ci","Performance Budgets and Lighthouse CI",{"path":1806,"title":1807},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fperformance-budgets-and-lighthouse-ci\u002Freducing-lighthouse-score-variance-in-ci","Reducing Lighthouse Score Variance in CI",{"path":1809,"title":1810},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fperformance-budgets-and-lighthouse-ci\u002Frunning-webpagetest-scripts-against-preview-deploys","Running WebPageTest Scripts Against Preview Deploys",{"path":1812,"title":1813},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fperformance-budgets-and-lighthouse-ci\u002Fsetting-up-lighthouse-ci-for-a-static-site","Setting Up Lighthouse CI for a Static Site",{"path":1815,"title":1816},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fperformance-budgets-and-lighthouse-ci\u002Ftracking-bundle-size-per-pull-request","Tracking Bundle Size per Pull Request",{"path":1818,"title":1819},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fperformance-budgets-and-lighthouse-ci\u002Fwriting-a-performance-budget-that-fails-builds","Writing a Performance Budget That Fails Builds",{"path":1821,"title":1822},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fresource-hints-and-navigation-speed\u002Fauditing-unused-preloads","Auditing Unused Preloads",{"path":1824,"title":1825},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fresource-hints-and-navigation-speed","Resource Hints and Navigation Speed",{"path":1827,"title":1828},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fresource-hints-and-navigation-speed\u002Finstant-navigation-with-speculation-rules","Instant Navigation with Speculation Rules",{"path":1830,"title":1831},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fresource-hints-and-navigation-speed\u002Fpreconnect-vs-dns-prefetch-on-static-sites","Preconnect vs DNS-Prefetch on Static Sites",{"path":1833,"title":1834},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fresource-hints-and-navigation-speed\u002Fprefetching-links-in-astro","Prefetching Links in Astro",{"path":1836,"title":1837},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fresource-hints-and-navigation-speed\u002Fview-transitions-on-multi-page-static-sites","View Transitions on Multi-Page Static Sites",{"path":1839,"title":1840},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fthird-party-script-performance-on-static-sites\u002Fauditing-third-party-scripts-with-lighthouse","Auditing Third-Party Scripts With Lighthouse",{"path":1842,"title":1843},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fthird-party-script-performance-on-static-sites","Third-Party Script Performance on Static Sites",{"path":1845,"title":1846},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fthird-party-script-performance-on-static-sites\u002Flazy-loading-youtube-embeds-on-static-sites","Lazy-Loading YouTube Embeds on Static Sites",{"path":1848,"title":1849},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fthird-party-script-performance-on-static-sites\u002Floading-google-tag-manager-without-hurting-inp","Loading Google Tag Manager Without Hurting INP",{"path":1851,"title":1852},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fthird-party-script-performance-on-static-sites\u002Frunning-third-party-scripts-in-a-web-worker-with-partytown","Running Third-Party Scripts in a Web Worker with Partytown",{"path":1854,"title":1855},"\u002Fperformance-optimization-core-web-vitals-for-ssgs\u002Fthird-party-script-performance-on-static-sites\u002Fself-hosting-analytics-to-cut-third-party-requests","Self-Hosting Analytics to Cut Third-Party Requests",{"path":1857,"title":1858},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcloudflare-pages-edge-caching-setup\u002Fautomating-eleventy-deployments-with-cloudflare-pages","Automating Eleventy Deployments on Cloudflare Pages",{"path":1860,"title":1861},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcloudflare-pages-edge-caching-setup\u002Fconfiguring-redirects-on-cloudflare-pages","Configuring Redirects on Cloudflare Pages",{"path":1863,"title":1864},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcloudflare-pages-edge-caching-setup\u002Fcustom-domains-and-tls-on-cloudflare-pages","Custom Domains and TLS on Cloudflare Pages",{"path":1866,"title":1867},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcloudflare-pages-edge-caching-setup\u002Fdeploying-hugo-to-cloudflare-pages-and-workers","Deploying Hugo to Cloudflare Pages and Workers",{"path":1869,"title":1870},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcloudflare-pages-edge-caching-setup","Cloudflare Pages Edge Caching Setup",{"path":1872,"title":1873},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcloudflare-pages-edge-caching-setup\u002Fmigrating-from-cloudflare-pages-to-workers-static-assets","Migrating from Cloudflare Pages to Workers Static Assets",{"path":1875,"title":1335},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcontent-workflows-for-documentation-teams\u002Fchecking-links-in-pull-requests",{"path":1877,"title":1878},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcontent-workflows-for-documentation-teams\u002Fdocs-as-code-review-workflow-for-writers","Docs-as-Code Review Workflow for Writers",{"path":1880,"title":1881},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcontent-workflows-for-documentation-teams\u002Feditorial-checks-with-vale-in-ci","Editorial Checks with Vale in CI",{"path":1883,"title":1884},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcontent-workflows-for-documentation-teams","Content Workflows for Documentation Teams",{"path":1886,"title":1887},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcontent-workflows-for-documentation-teams\u002Fscheduling-content-publication-with-cron-triggered-builds","Scheduling Content Publication With Cron-Triggered Builds",{"path":1889,"title":1890},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fcontent-workflows-for-documentation-teams\u002Fwiring-a-headless-cms-to-a-static-build","Wiring a Headless CMS to a Static Build",{"path":1892,"title":1893},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fgithub-actions-for-automated-ssg-builds\u002Fbuilding-astro-sites-with-github-actions","Building Astro Sites with GitHub Actions",{"path":1895,"title":1896},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fgithub-actions-for-automated-ssg-builds\u002Fcaching-node-modules-in-github-actions-for-faster-ssg-builds","Caching node_modules in GitHub Actions",{"path":1898,"title":1899},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fgithub-actions-for-automated-ssg-builds\u002Fdeploying-to-github-pages-with-actions","Deploying to GitHub Pages with Actions",{"path":1901,"title":1902},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fgithub-actions-for-automated-ssg-builds\u002Fdeploying-to-multiple-environments-from-one-workflow","Deploying to Multiple Environments From One Workflow",{"path":1904,"title":1905},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fgithub-actions-for-automated-ssg-builds\u002Fhow-to-set-up-github-actions-for-hugo-deployments","GitHub Actions for Hugo Deployments",{"path":1907,"title":1908},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fgithub-actions-for-automated-ssg-builds","GitHub Actions for Automated SSG Builds",{"path":1910,"title":1911},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fgithub-actions-for-automated-ssg-builds\u002Fmatrix-builds-for-multi-site-monorepos","Matrix Builds for Multi-Site Monorepos",{"path":1913,"title":1914},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fincremental-builds-and-build-caching-for-ssgs\u002Fcaching-hugo-builds-in-github-actions","Caching Hugo Builds in GitHub Actions",{"path":1916,"title":1917},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fincremental-builds-and-build-caching-for-ssgs\u002Fenabling-incremental-builds-in-eleventy","Enabling Incremental Builds in Eleventy",{"path":1919,"title":1920},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fincremental-builds-and-build-caching-for-ssgs\u002Fincremental-builds-in-astro-with-the-content-layer","Incremental Builds in Astro with the Content Layer",{"path":1922,"title":1923},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fincremental-builds-and-build-caching-for-ssgs","Incremental Builds and Build Caching for SSGs",{"path":1925,"title":1926},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fincremental-builds-and-build-caching-for-ssgs\u002Fmeasuring-build-time-regressions-in-ci","Measuring Build-Time Regressions in CI",{"path":1928,"title":1929},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fincremental-builds-and-build-caching-for-ssgs\u002Fremote-caching-with-turborepo-for-ssg-monorepos","Remote Caching with Turborepo for SSG Monorepos",{"path":1931,"title":1932},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fincremental-builds-and-build-caching-for-ssgs\u002Fsharing-build-cache-across-ci-runners","Sharing Build Cache Across CI Runners",{"path":1934,"title":1935},"\u002Fproduction-ready-deployment-cicd-workflows","Production-Ready Deployment & CI\u002FCD for SSGs",{"path":1937,"title":1938},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fmonitoring-static-sites-in-production\u002Falerting-on-cache-hit-ratio-drops","Alerting on Cache Hit Ratio Drops",{"path":1940,"title":1941},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fmonitoring-static-sites-in-production\u002Fbuilding-a-core-web-vitals-dashboard-from-rum-data","Building a Core Web Vitals Dashboard from RUM Data",{"path":1943,"title":1944},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fmonitoring-static-sites-in-production\u002Fcrawling-for-broken-links-on-a-schedule","Crawling for Broken Links on a Schedule",{"path":1946,"title":1947},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fmonitoring-static-sites-in-production","Monitoring Static Sites in Production",{"path":1949,"title":1950},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fmonitoring-static-sites-in-production\u002Flogging-404s-at-the-edge","Logging 404s at the Edge",{"path":1952,"title":1953},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fmonitoring-static-sites-in-production\u002Fuptime-and-synthetic-checks-for-static-sites","Uptime and Synthetic Checks for Static Sites",{"path":1955,"title":1956},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fnetlify-vs-vercel-deployment-strategies\u002Fconfiguring-vercel-for-hugo-and-eleventy","Configuring Vercel for Hugo and Eleventy",{"path":1958,"title":1959},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fnetlify-vs-vercel-deployment-strategies","Netlify vs Vercel Deployment Strategies",{"path":1961,"title":1962},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fnetlify-vs-vercel-deployment-strategies\u002Fnetlify-build-hooks-for-content-updates","Netlify Build Hooks for Content Updates",{"path":1964,"title":1965},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fnetlify-vs-vercel-deployment-strategies\u002Fnetlify-redirects-and-rewrites-for-static-sites","Netlify Redirects and Rewrites for Static Sites",{"path":1967,"title":1968},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fnetlify-vs-vercel-deployment-strategies\u002Fsetting-up-deploy-previews-on-netlify-for-every-pull-request","Netlify Deploy Previews for Every Pull Request",{"path":1970,"title":1971},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fnetlify-vs-vercel-deployment-strategies\u002Fvercel-isr-vs-static-generation-for-ssgs","Vercel ISR vs Static Generation for SSGs",{"path":1973,"title":1974},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fpreview-environments-for-pull-requests\u002Fautomating-preview-deploy-pipelines-with-github-actions","Automating Preview Deploy Pipelines with GitHub Actions",{"path":1976,"title":1977},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fpreview-environments-for-pull-requests\u002Fcleaning-up-stale-preview-deployments","Cleaning Up Stale Preview Deployments",{"path":1979,"title":1980},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fpreview-environments-for-pull-requests","Preview Environments for Pull Requests",{"path":1982,"title":1983},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fpreview-environments-for-pull-requests\u002Fpassword-protecting-preview-deployments","Password-Protecting Preview Deployments",{"path":1985,"title":1986},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fpreview-environments-for-pull-requests\u002Fpreviewing-headless-cms-drafts","Previewing Headless CMS Drafts",{"path":1988,"title":1989},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fpreview-environments-for-pull-requests\u002Fvisual-regression-testing-on-preview-deploys","Visual Regression Testing on Preview Deploys",{"path":1991,"title":1992},"\u002Fproduction-ready-deployment-cicd-workflows\u002Frollbacks-and-deploy-safety-for-static-sites\u002Fatomic-deploys-vs-incremental-uploads","Atomic Deploys vs Incremental Uploads",{"path":1994,"title":1995},"\u002Fproduction-ready-deployment-cicd-workflows\u002Frollbacks-and-deploy-safety-for-static-sites\u002Fcanary-releases-for-static-sites","Canary Releases for Static Sites",{"path":1997,"title":1998},"\u002Fproduction-ready-deployment-cicd-workflows\u002Frollbacks-and-deploy-safety-for-static-sites\u002Ffeature-flags-on-static-sites","Feature Flags on Static Sites",{"path":2000,"title":2001},"\u002Fproduction-ready-deployment-cicd-workflows\u002Frollbacks-and-deploy-safety-for-static-sites","Rollbacks and Deploy Safety for Static Sites",{"path":2003,"title":2004},"\u002Fproduction-ready-deployment-cicd-workflows\u002Frollbacks-and-deploy-safety-for-static-sites\u002Frolling-back-a-bad-static-deploy-in-under-a-minute","Rolling Back a Bad Static Deploy in Under a Minute",{"path":2006,"title":1188},"\u002Fproduction-ready-deployment-cicd-workflows\u002Frollbacks-and-deploy-safety-for-static-sites\u002Frunning-smoke-tests-against-a-preview-url",{"path":2008,"title":2009},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fsecurity-headers-for-static-sites\u002Fauditing-npm-dependencies-in-ssg-pipelines","Auditing npm Dependencies in SSG Pipelines",{"path":2011,"title":2012},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fsecurity-headers-for-static-sites\u002Fenabling-hsts-and-preload-safely","Enabling HSTS and Preload Safely",{"path":2014,"title":2015},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fsecurity-headers-for-static-sites\u002Fhash-based-csp-for-inline-scripts-in-astro","Hash-Based CSP for Inline Scripts in Astro",{"path":2017,"title":2018},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fsecurity-headers-for-static-sites","Security Headers and Hardening for Static Sites",{"path":2020,"title":2021},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fsecurity-headers-for-static-sites\u002Fsecuring-deploy-credentials-with-github-oidc","Securing Deploy Credentials with GitHub OIDC",{"path":2023,"title":2024},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fsecurity-headers-for-static-sites\u002Fsubresource-integrity-for-third-party-assets","Subresource Integrity for Third-Party Assets",{"path":2026,"title":2027},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fsecurity-headers-for-static-sites\u002Fwriting-a-content-security-policy-for-a-static-site","Writing a Content Security Policy for a Static Site",{"path":1515,"title":5},{"path":2030,"title":1452},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fcloudfront-functions-for-redirects",{"path":2032,"title":58},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fdeploying-a-static-site-to-s3-and-cloudfront",{"path":2034,"title":53},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites",{"path":2036,"title":2037},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fserving-a-static-site-with-caddy","Serving a Static Site with Caddy",{"path":2039,"title":2040},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fserving-a-static-site-with-nginx","Serving a Static Site with Nginx",{"path":2042,"title":2043},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fself-hosting-static-sites\u002Fzero-downtime-deploys-with-symlink-swaps","Zero-Downtime Deploys with Symlink Swaps",{"path":2045,"title":2046},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fserverless-functions-for-static-sites\u002Fadding-a-contact-form-with-cloudflare-workers","Adding a Contact Form with Cloudflare Workers",{"path":2048,"title":2049},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fserverless-functions-for-static-sites\u002Fhandling-form-submissions-on-a-static-site","Handling Form Submissions on a Static Site",{"path":2051,"title":2052},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fserverless-functions-for-static-sites","Serverless Functions for Static Sites",{"path":2054,"title":2055},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fserverless-functions-for-static-sites\u002Fnetlify-functions-vs-cloudflare-workers","Netlify Functions vs Cloudflare Workers",{"path":2057,"title":2058},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fserverless-functions-for-static-sites\u002Fprotecting-a-static-site-behind-authentication","Protecting a Static Site Behind Authentication",{"path":2060,"title":2061},"\u002Fproduction-ready-deployment-cicd-workflows\u002Fserverless-functions-for-static-sites\u002Fproxying-third-party-apis-from-an-edge-function","Proxying Third-Party APIs from an Edge Function",1789722847271]