{"id":333,"date":"2025-03-20T07:00:00","date_gmt":"2025-03-20T06:00:00","guid":{"rendered":"http:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/"},"modified":"2025-03-20T07:00:00","modified_gmt":"2025-03-20T06:00:00","slug":"how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr","status":"publish","type":"post","link":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/","title":{"rendered":"How to Add Search to a Static WordPress Site for Free Using Lunr"},"content":{"rendered":"<p>If you have a static WordPress site or you&#8217;re strongly considering launching one, then you&#8217;re probably already aware of its default limitations. One of the big ones is the inability to add a search function to your site. But with a little bit of creative thinking, you can use a free, open-source JavaScript library called Lunr (along with a few other tools) to get around that problem and build one anyway. Here&#8217;s how&#8230;<\/p>","protected":false},"excerpt":{"rendered":"<p>If you have a static WordPress site or you&#8217;re strongly considering launching one, then you&#8217;re probably already aware of its default limitations. One of the big ones is the inability to add a search function to your site. But with a little bit of creative thinking, you can use a free, open-source JavaScript library called&#8230;<\/p>\n","protected":false},"author":0,"featured_media":334,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_kadence_starter_templates_imported_post":false,"_kad_post_transparent":"","_kad_post_title":"","_kad_post_layout":"","_kad_post_sidebar_id":"","_kad_post_content_style":"","_kad_post_vertical_padding":"","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"footnotes":""},"categories":[1],"tags":[],"class_list":["post-333","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-non-classe"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v23.4 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to Add Search to a Static WordPress Site for Free Using Lunr - WordPress<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Add Search to a Static WordPress Site for Free Using Lunr - WordPress\" \/>\n<meta property=\"og:description\" content=\"If you have a static WordPress site or you&#8217;re strongly considering launching one, then you&#8217;re probably already aware of its default limitations. One of the big ones is the inability to add a search function to your site. But with a little bit of creative thinking, you can use a free, open-source JavaScript library called...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/\" \/>\n<meta property=\"og:site_name\" content=\"WordPress\" \/>\n<meta property=\"article:published_time\" content=\"2025-03-20T06:00:00+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg\" \/>\n\t<meta property=\"og:image:width\" content=\"1280\" \/>\n\t<meta property=\"og:image:height\" content=\"720\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/\"},\"author\":{\"name\":\"\",\"@id\":\"\"},\"headline\":\"How to Add Search to a Static WordPress Site for Free Using Lunr\",\"datePublished\":\"2025-03-20T06:00:00+00:00\",\"dateModified\":\"2025-03-20T06:00:00+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/\"},\"wordCount\":86,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/geo-info.fr\/#organization\"},\"image\":{\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg\",\"articleSection\":[\"Non class\u00e9\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/\",\"url\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/\",\"name\":\"How to Add Search to a Static WordPress Site for Free Using Lunr - WordPress\",\"isPartOf\":{\"@id\":\"https:\/\/geo-info.fr\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg\",\"datePublished\":\"2025-03-20T06:00:00+00:00\",\"dateModified\":\"2025-03-20T06:00:00+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#primaryimage\",\"url\":\"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg\",\"contentUrl\":\"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg\",\"width\":1280,\"height\":720},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Accueil\",\"item\":\"https:\/\/geo-info.fr\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Add Search to a Static WordPress Site for Free Using Lunr\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/geo-info.fr\/#website\",\"url\":\"https:\/\/geo-info.fr\/\",\"name\":\"WordPress\",\"description\":\"Un site utilisant WordPress\",\"publisher\":{\"@id\":\"https:\/\/geo-info.fr\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/geo-info.fr\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/geo-info.fr\/#organization\",\"name\":\"WordPress\",\"url\":\"https:\/\/geo-info.fr\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/geo-info.fr\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/geo-info.fr\/wp-content\/uploads\/2024\/09\/TECHSOL.png\",\"contentUrl\":\"https:\/\/geo-info.fr\/wp-content\/uploads\/2024\/09\/TECHSOL.png\",\"width\":5000,\"height\":3106,\"caption\":\"WordPress\"},\"image\":{\"@id\":\"https:\/\/geo-info.fr\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Add Search to a Static WordPress Site for Free Using Lunr - WordPress","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/","og_locale":"en_US","og_type":"article","og_title":"How to Add Search to a Static WordPress Site for Free Using Lunr - WordPress","og_description":"If you have a static WordPress site or you&#8217;re strongly considering launching one, then you&#8217;re probably already aware of its default limitations. One of the big ones is the inability to add a search function to your site. But with a little bit of creative thinking, you can use a free, open-source JavaScript library called...","og_url":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/","og_site_name":"WordPress","article_published_time":"2025-03-20T06:00:00+00:00","og_image":[{"width":1280,"height":720,"url":"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg","type":"image\/jpeg"}],"twitter_card":"summary_large_image","schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#article","isPartOf":{"@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/"},"author":{"name":"","@id":""},"headline":"How to Add Search to a Static WordPress Site for Free Using Lunr","datePublished":"2025-03-20T06:00:00+00:00","dateModified":"2025-03-20T06:00:00+00:00","mainEntityOfPage":{"@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/"},"wordCount":86,"commentCount":0,"publisher":{"@id":"https:\/\/geo-info.fr\/#organization"},"image":{"@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#primaryimage"},"thumbnailUrl":"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg","articleSection":["Non class\u00e9"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/","url":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/","name":"How to Add Search to a Static WordPress Site for Free Using Lunr - WordPress","isPartOf":{"@id":"https:\/\/geo-info.fr\/#website"},"primaryImageOfPage":{"@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#primaryimage"},"image":{"@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#primaryimage"},"thumbnailUrl":"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg","datePublished":"2025-03-20T06:00:00+00:00","dateModified":"2025-03-20T06:00:00+00:00","breadcrumb":{"@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#primaryimage","url":"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg","contentUrl":"https:\/\/geo-info.fr\/wp-content\/uploads\/2025\/03\/l8yuk3lxiny-VDTJVC.jpeg","width":1280,"height":720},{"@type":"BreadcrumbList","@id":"https:\/\/geo-info.fr\/index.php\/2025\/03\/20\/how-to-add-search-to-a-static-wordpress-site-for-free-using-lunr\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Accueil","item":"https:\/\/geo-info.fr\/"},{"@type":"ListItem","position":2,"name":"How to Add Search to a Static WordPress Site for Free Using Lunr"}]},{"@type":"WebSite","@id":"https:\/\/geo-info.fr\/#website","url":"https:\/\/geo-info.fr\/","name":"WordPress","description":"Un site utilisant WordPress","publisher":{"@id":"https:\/\/geo-info.fr\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/geo-info.fr\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/geo-info.fr\/#organization","name":"WordPress","url":"https:\/\/geo-info.fr\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/geo-info.fr\/#\/schema\/logo\/image\/","url":"https:\/\/geo-info.fr\/wp-content\/uploads\/2024\/09\/TECHSOL.png","contentUrl":"https:\/\/geo-info.fr\/wp-content\/uploads\/2024\/09\/TECHSOL.png","width":5000,"height":3106,"caption":"WordPress"},"image":{"@id":"https:\/\/geo-info.fr\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/geo-info.fr\/index.php\/wp-json\/wp\/v2\/posts\/333","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/geo-info.fr\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/geo-info.fr\/index.php\/wp-json\/wp\/v2\/types\/post"}],"replies":[{"embeddable":true,"href":"https:\/\/geo-info.fr\/index.php\/wp-json\/wp\/v2\/comments?post=333"}],"version-history":[{"count":0,"href":"https:\/\/geo-info.fr\/index.php\/wp-json\/wp\/v2\/posts\/333\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/geo-info.fr\/index.php\/wp-json\/wp\/v2\/media\/334"}],"wp:attachment":[{"href":"https:\/\/geo-info.fr\/index.php\/wp-json\/wp\/v2\/media?parent=333"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/geo-info.fr\/index.php\/wp-json\/wp\/v2\/categories?post=333"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/geo-info.fr\/index.php\/wp-json\/wp\/v2\/tags?post=333"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}