CINXE.COM
Docs
<!doctype html> <html lang="en" class="scroll-smooth w-full"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> <meta name="generator" content="Hugo 0.143.1"> <link rel="alternate" type="application/rss+xml" href="https://redis.io/docs/latest/index.xml"> <meta name="robots" content="index, follow"> <meta name="google-site-verification" content="suIo51jDr2z6o48kiD53RKtRvp-JgZ-njy8SWMdrkMo"> <link rel="canonical" href="https://redis.io/docs/latest/" /> <link rel="manifest" href="/docs/latest/images/favicons/site.webmanifest"> <meta name="theme-color" content="#ffffff"> <link rel="apple-touch-icon-precomposed" sizes="57x57" href="/docs/latest/images/favicons/apple-touch-icon-57x57.png" /> <link rel="apple-touch-icon-precomposed" sizes="114x114" href="/docs/latest/images/favicons/apple-touch-icon-114x114.png" /> <link rel="apple-touch-icon-precomposed" sizes="72x72" href="/docs/latest/images/favicons/apple-touch-icon-72x72.png" /> <link rel="apple-touch-icon-precomposed" sizes="144x144" href="/docs/latest/images/favicons/apple-touch-icon-144x144.png" /> <link rel="apple-touch-icon-precomposed" sizes="60x60" href="/docs/latest/images/favicons/apple-touch-icon-60x60.png" /> <link rel="apple-touch-icon-precomposed" sizes="120x120" href="/docs/latest/images/favicons/apple-touch-icon-120x120.png" /> <link rel="apple-touch-icon-precomposed" sizes="76x76" href="/docs/latest/images/favicons/apple-touch-icon-76x76.png" /> <link rel="apple-touch-icon-precomposed" sizes="152x152" href="/docs/latest/images/favicons/apple-touch-icon-152x152.png" /> <link rel="icon" type="image/png" href="/docs/latest/images/favicons/favicon-196x196.png" sizes="196x196" /> <link rel="icon" type="image/png" href="/docs/latest/images/favicons/favicon-96x96.png" sizes="96x96" /> <link rel="icon" type="image/png" href="/docs/latest/images/favicons/favicon-32x32.png" sizes="32x32" /> <link rel="icon" type="image/png" href="/docs/latest/images/favicons/favicon-16x16.png" sizes="16x16" /> <link rel="icon" type="image/png" href="/docs/latest/images/favicons/favicon-128.png" sizes="128x128" /> <meta name="application-name" content=" "/> <meta name="msapplication-TileColor" content="#FFFFFF" /> <meta name="msapplication-TileImage" content="/docs/latest/images/favicons/mstile-144x144.png" /> <meta name="msapplication-square70x70logo" content="/docs/latest/images/favicons/mstile-70x70.png" /> <meta name="msapplication-square150x150logo" content="/docs/latest/images/favicons/mstile-150x150.png" /> <meta name="msapplication-wide310x150logo" content="/docs/latest/images/favicons/mstile-310x150.png" /> <meta name="msapplication-square310x310logo" content="/docs/latest/images/favicons/mstile-310x310.png" /> <title>Docs</title> <meta name="description" content=""> <meta property="og:url" content="https://redis.io/docs/latest/"> <meta property="og:site_name" content="Docs"> <meta property="og:title" content="Docs"> <meta property="og:locale" content="en"> <meta property="og:type" content="website"> <meta itemprop="name" content="Docs"> <meta itemprop="datePublished" content="2025-04-01T00:00:00+00:00"> <meta itemprop="dateModified" content="2025-04-04T13:37:55-04:00"> <meta name="twitter:card" content="summary"> <meta name="twitter:title" content="Docs"> <link rel="preload" href="/docs/latest/scss/style.min.65324e4de191c292ee8b6f4f0ebf01320e8c4bc8623b04e9dfad322ebb490b31.css" as="style"> <link href="/docs/latest/scss/style.min.65324e4de191c292ee8b6f4f0ebf01320e8c4bc8623b04e9dfad322ebb490b31.css" rel="stylesheet" integrity=""> <link href="/docs/latest/css/index.min.fc97c7d4a9fdfdd0a490a1cf509319056f751cccebb4a091c4cc7e76c38f26c6.css" rel="stylesheet" /> <script src='/docs/latest/js/cli.js' defer></script> <style> @font-face { font-family: 'Space Mono'; src: url('/docs/latest/fonts/SpaceMono-Regular.ttf') format('truetype'); font-weight: 400; font-style: normal; font-display: swap; } @font-face { font-family: 'Space Mono'; src: url('/docs/latest/fonts/SpaceMono-Bold.ttf') format('truetype'); font-weight: 700; font-style: normal; font-display: swap; } @font-face { font-family: 'Space Grotesk'; src: url('/docs/latest/fonts/SpaceGrotesk-VariableFont_wght.ttf') format('truetype'); font-style: normal; font-display: swap; } @font-face { font-family: 'TT Trailers'; src: url('/docs/latest/fonts/TT_Trailers_Bold.woff2') format('woff2'); font-weight: 700; font-style: normal; font-display: swap; } @font-face { font-family: 'Geist'; src: url('/docs/latest/fonts/Geist-Regular.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; } @font-face { font-family: 'Geist Mono'; src: url('/docs/latest/fonts/GeistMono-Regular.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; } </style> <link rel="preload" href='/docs/latest/fonts/SpaceMono-Regular.ttf' as="font" type="font/ttf" crossorigin /> <link rel="preload" href='/docs/latest/fonts/SpaceMono-Bold.ttf' as="font" type="font/ttf" crossorigin /> <link rel="preload" href='/docs/latest/fonts/SpaceGrotesk-VariableFont_wght.ttf' as="font" type="font/ttf" crossorigin /> <link rel="preload" href='/docs/latest/fonts/TT_Trailers_Bold.woff2' as="font" type="font/woff2" crossorigin /> <link rel="preload" href='/docs/latest/fonts/Geist-Regular.woff2' as="font" type="font/woff2" crossorigin /> <link rel="preload" href='/docs/latest/fonts/GeistMono-Regular.woff2' as="font" type="font/woff2" crossorigin /> <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src= 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); })(window,document,'script','dataLayer','GTM-TKZ6J9R');</script> <script src='/docs/latest/js/index.js' defer></script> </head> <body class="antialiased tracking-[-0.01em] bg-white w-full"> <noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-TKZ6J9R" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript> <header class="sticky top-0 h-[70px] z-50 w-full border-b border-redis-pen-300 bg-white text-midnight-900 font-mono text-[15px] flex justify-center"> <div class="flex h-[70px] px-4 lg:pl-11 lg:pr-0 items-center self-center grow"> <a class="relative text-redis-red-500 w-[82px] -mt-[5px] mr-[4px]" href="https://redis.io/"> <svg width="100%" height="100%" viewBox="0 0 85 27" fill="none" xmlns="http://www.w3.org/2000/svg"> <g clip-path="url(#clip0_8_219)"> <path fill-rule="evenodd" clip-rule="evenodd" d="M75.2909 13.8125C75.2909 10.8448 77.4892 9.12284 80.2371 9.12284C82.2888 9.12284 84.1207 10.1121 85 12.5668C84.7435 13.8125 83.2047 15.2047 82.5453 15.4246C81.9957 14.2522 81.3728 13.556 80.7866 13.556C80.0539 13.556 80.0172 14.069 80.0172 14.7284C80.0172 15.1955 80.151 15.8834 80.3119 16.7112C80.5549 17.9615 80.8599 19.5309 80.8599 21.1401C80.8599 24.0711 78.8082 26.2328 75.6573 26.2328C72.7721 26.2328 71.1778 24.3414 70.4665 21.3198C68.5818 24.6972 65.8257 26.2328 63.7134 26.2328C60.411 26.2328 59.6338 23.7919 59.7121 21.3161C58.3852 23.6612 55.831 26.2328 53.3815 26.2328C50.8809 26.2328 49.9976 24.0563 50.2002 21.5215C48.702 24.3122 45.9919 26.2328 43.3793 26.2328C40.5442 26.2328 39.141 23.9806 39.5951 21.189C37.6878 23.5333 34.1374 26.2328 30.4461 26.2328C26.2373 26.2328 24.4053 23.9632 24.1882 21.1193C22.1568 24.375 19.4187 26.3427 16.1573 26.3427C11.4493 26.3427 9.76537 22.1561 9.52032 18.7315C7.77547 21.0681 5.81377 23.4923 3.40733 26.1961C3.15086 26.4526 2.93103 26.5991 2.67457 26.5991C1.8319 26.5991 0.109914 22.8621 0 21.4698C0.723099 20.3478 5.28119 15.3398 8.95093 11.3079C10.2409 9.89066 11.4211 8.594 12.2863 7.6291C10.0389 8.30726 7.72169 9.65975 4.79957 11.7608C4.28664 12.1272 2.85776 8.7931 2.8944 6.22845C6.26509 3.73707 11.3944 2.16164 15.5345 2.16164C21.3233 2.16164 24.6573 5.38578 24.6573 9.8556C24.6573 13.5927 21.5431 17.6961 17 17.8427C14.6377 17.904 13.1237 16.578 12.3494 14.9405C12.4419 17.473 13.7587 20.5905 17.2931 20.5905C21.1462 20.5905 22.9965 18.2646 25.7559 14.7958C25.9352 14.5704 26.1183 14.3403 26.306 14.1056C28.6509 11.2112 31.3621 8.64655 35.319 8.64655C37.7371 8.64655 39.3858 10.1487 39.3858 12.4203C39.3858 15.1681 36.1616 18.9784 31.6552 18.9784C30.8855 18.9784 30.1839 18.877 29.5917 18.6766C29.5768 18.7921 29.5668 18.9058 29.5668 19.0151C29.5668 20.2974 30.0431 21.0668 32.1315 21.0668C35.2091 21.0668 38.1034 19.2349 41.6207 14.9483C45.0647 10.7349 47.6659 8.90302 50.4138 8.90302C52.2687 8.90302 53.6765 9.90832 54.2969 11.6014C57.9796 6.28253 61.1038 2.51388 63.75 0C66.3513 1.09914 68.2198 3.26078 67.7069 3.70043C65.7651 5.45905 59.2802 12.5302 56.7155 16.7435C56.056 17.8427 55.4332 19.0517 55.4332 19.6379C55.4332 20.1875 55.7629 20.3707 56.1293 20.3707C57.8898 20.3707 61.4176 16.2147 64.4645 12.6253C65.6026 11.2845 66.6736 10.0228 67.5603 9.08621C69.6121 9.92888 71.7004 11.7241 71.1875 12.347C68.4763 15.5711 66.4246 18.2091 66.4246 19.7112C66.4246 20.1142 66.5711 20.3707 67.1207 20.3707C68.1466 20.3707 69.0991 19.4547 70.6746 17.5129C71.0043 17.1099 71.4073 17.1099 71.6638 17.7328C72.3599 19.4181 73.3858 20.3341 74.1918 20.3341C75.1444 20.3341 75.6207 19.4914 75.6207 18.2091C75.6207 17.3327 75.5137 16.3138 75.4217 15.4365C75.3521 14.7733 75.2909 14.191 75.2909 13.8125ZM16.194 13.3362C18.1358 13.3362 20.2608 12.2737 20.2608 10.1121C20.2608 8.80024 19.4466 7.59084 17.2708 7.22257C17.156 7.40192 17.042 7.58017 16.9287 7.75739C15.8231 9.4858 14.7804 11.116 13.7281 12.7095C14.3586 13.0636 15.156 13.3362 16.194 13.3362ZM35.8319 13.9957C35.8319 13.4095 35.4655 13.0065 34.8793 13.0065C33.4094 13.0065 31.1923 15.0693 30.149 17.0613C30.5341 17.2101 30.9862 17.2931 31.472 17.2931C34.0733 17.2931 35.8319 15.3147 35.8319 13.9957ZM45.4677 19.3082C45.4677 19.9677 45.834 20.4073 46.6034 20.4073C48.9849 20.4073 51.9526 16.0841 51.9526 14.3254C51.9526 13.5927 51.5496 13.153 50.8901 13.153C48.7285 13.153 45.4677 17.2565 45.4677 19.3082ZM76.0599 6.08207C75.2172 7.47431 73.9349 9.04974 73.4586 9.52603C71.2603 8.61008 69.2086 6.77819 69.5017 6.26525C70.3077 4.83638 71.6267 3.29758 72.103 2.82129C74.3012 3.73724 76.353 5.60577 76.0599 6.08207Z" fill="currentColor"/> </g> <defs> <clipPath id="clip0_8_219"> <rect width="85" height="26.5991" fill="white"/> </clipPath> </defs> </svg> </a> <div class="h-full flex items-center mx-4 grow"> <div class="hidden lg:flex flex-row h-full items-center"> <div class="group h-full px-2 xl:px-[14px]"> <div class="flex flex-row h-full items-center cursor-pointer w-[10ch] justify-between"> <span class="inline-block group-hover:font-bold">Products</span> <span class="inline-block ml-2 mt-1 text-redis-red-500 group-hover:rotate-180 transition-all ease-in-out duration-200"><svg width="12" height="6" viewBox="0 0 12 6" fill="currentColor" xmlns="http://www.w3.org/2000/svg"> <path fill-rule="evenodd" clip-rule="evenodd" d="M5.29289 6L0.646484 1.35359L1.35359 0.646484L6.00004 5.29293L10.6465 0.646484L11.3536 1.35359L6.70718 6H5.29289Z"/> </svg> </span> </div> <div class="flex flex-col font-sans lg:hidden lg:group-hover:flex lg:absolute lg:left-20 lg:border lg:border-redis-pencil-300 bg-white lg:flex-row lg:rounded-b-md gap-8 text-[15px]"> <div class="p-10"> <h2 class="mb-6 border-b border-redis-pencil-250 pb-2 text-xs font-medium uppercase tracking-[2px] text-gray-400"> Products</h2> <ul class="grid grid-cols-2 gap-x-7 gap-y-3.5"> <li class="w-[16rem]"> <a class="font-medium hover:text-redis-red-500" href="https://redis.io/cloud/"> Redis Cloud <p class="mt-2 text-xs font-normal text-gray-600">Fully managed and integrated with Google Cloud, Azure, and AWS.</p> </a> </li> <li class="w-[16rem]"> <a class="font-medium hover:text-redis-red-500" href="https://redis.io/redis-for-ai/"> Redis for AI <p class="mt-2 text-xs font-normal text-gray-600">Build the fastest, most reliable GenAI apps with our advanced vector database.</p> </a> </li> <li class="w-[16rem]"> <a class="font-medium hover:text-redis-red-500" href="https://redis.io/software/"> Redis Software <p class="mt-2 text-xs font-normal text-gray-600">Self-managed software with enterprise-grade compliance and reliability.</p> </a> </li> <li class="w-[16rem]"> <a class="font-medium hover:text-redis-red-500" href="https://redis.io/data-integration/"> Redis Data Integration (RDI) <p class="mt-2 text-xs font-normal text-gray-600">Synchronize data in near-real time to make data fast—without writing code.</p> </a> </li> <li class="w-[16rem]"> <a class="font-medium hover:text-redis-red-500" href="https://redis.io/docs/latest/get-started/"> Community Edition <p class="mt-2 text-xs font-normal text-gray-600">In-memory database for caching & streaming.</p> </a> </li> </ul> </div> <div class="flex flex-col bg-redis-neutral-200 p-8"> <div class="mb-4"> <h2 class="mb-6 border-b border-redis-pencil-250 pb-2 text-xs font-medium uppercase tracking-[2px] text-gray-400"> Tools</h2> <ul class="space-y-4"> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/insight/">Redis Insight</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/clients/">Clients and connectors</a></li> </ul> </div> <div class="mt-auto"> <h2 class="mb-6 pb-2 text-xs font-medium uppercase tracking-[2px] text-gray-400">Get Redis</h2><a class="w-9/12 rounded border border-redis-pen-600 bg-redis-yellow-500 px-6 py-4 font-mono font-normal hover:bg-redis-pen-800 hover:text-white" href="https://redis.io/downloads/">Downloads</a> </div> </div> </div> </div> <div class="group h-full px-2 xl:px-[14px]"> <div class="flex flex-row h-full items-center cursor-pointer w-[11ch] justify-between"> <span class="inline-block group-hover:font-bold">Resources</span> <span class="inline-block ml-2 mt-1 text-redis-red-500 group-hover:rotate-180 transition-all ease-in-out duration-200"><svg width="12" height="6" viewBox="0 0 12 6" fill="currentColor" xmlns="http://www.w3.org/2000/svg"> <path fill-rule="evenodd" clip-rule="evenodd" d="M5.29289 6L0.646484 1.35359L1.35359 0.646484L6.00004 5.29293L10.6465 0.646484L11.3536 1.35359L6.70718 6H5.29289Z"/> </svg> </span> </div> <div class="flex flex-col font-sans lg:hidden lg:group-hover:flex lg:absolute lg:left-20 lg:border lg:border-redis-pencil-300 bg-white lg:flex-row lg:rounded-b-md gap-8 text-[15px]"> <div class="p-10"> <div> <h2 class="mb-6 border-b border-redis-pencil-250 pb-2 text-xs font-medium uppercase tracking-[2px] text-gray-400"> Connect</h2> <ul class="grid grid-cols-3 gap-x-7 gap-y-3.5"> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/customers/">Customer Stories</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/partners/">Partners</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/support/">Support</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/community/">Community</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/events/">Events & Webinars</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/services/professional-services/">Professional Services</a></li> </ul> </div> <div> <h2 class="mb-6 mt-12 border-b border-redis-pencil-250 pb-2 text-xs font-medium uppercase tracking-[2px] text-gray-400"> Learn</h2> <ul class="grid grid-cols-3 gap-x-7 gap-y-3.5"> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/docs/">Docs</a> </li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/commands/">Commands</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/docs/latest/get-started/">Quick starts</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/learn/">Tutorials</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://university.redis.io/">University</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/kb/">Knowledge Base</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/resources/">Resources</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/blog/">Blog</a> </li> </ul> </div> </div> <div class="flex flex-col bg-redis-neutral-200 p-10"> <div class="mb-4"> <h2 class="mb-6 border-b border-redis-pencil-250 pb-2 text-xs font-medium uppercase tracking-[2px] text-gray-400"> Latest</h2> <ul class="space-y-4"> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/release/">Releases</a></li> <li><a class="font-medium hover:text-redis-red-500" href="https://redis.io/company/news/">News & Updates</a></li> </ul> </div> <div class="mt-auto"> <h2 class="mb-6 pb-2 text-xs font-medium uppercase tracking-[2px] text-gray-400">See how it works</h2><a class="w-9/12 rounded border border-redis-pen-600 bg-redis-yellow-500 p-4 font-mono font-normal hover:bg-redis-pen-800 hover:text-white" href="https://redis.io/demo-center/"><span>Visit Demo Center</span></a> </div> </div> </div> </div> </div> <a class="hidden lg:flex group flex-row items-center px-4" href="https://redis.io/docs/"><span class="font-bold">Docs</span></a> <a class="hidden lg:flex group flex-row items-center px-4" href="https://redis.io/pricing/"><span class="group-hover:font-bold">Pricing</span></a> </div> <div class="h-full flex gap-[18px] xl:gap-7 items-center text-center"> <button id="search-button" type="button" class="p-1 mt-1 transition-colors hover:text-redis-red-500"> <svg width="18" height="19" viewBox="0 0 18 19" stroke="currentColor" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M14.25 7.72059C14.25 11.591 11.2076 14.6912 7.5 14.6912C3.79242 14.6912 0.75 11.591 0.75 7.72059C0.75 3.8502 3.79242 0.75 7.5 0.75C11.2076 0.75 14.25 3.8502 14.25 7.72059Z" stroke-width="1.5"/> <path d="M12 12.3529L17 17.5" stroke-width="1.5"/> </svg> </button> <a class="hidden lg:block py-1 transition-colors hover:text-redis-red-500" href="https://cloud.redis.io/">Login</a> <a class="hidden lg:block py-1 transition-colors hover:text-redis-red-500" href="https://redis.io/meeting/">Book a meeting</a> <a class="hidden lg:inline-flex transition-colors hover:duration-0 duration-500 ease-out items-center justify-center bg-redis-red-500 hover:bg-redis-yellow-500 hover:text-midnight-900 h-full px-[27px]" href="https://redis.io/try-free/">Try Redis</a> <button data-menu-toggle aria-expanded="false" type="button" class="menu-toggle lg:hidden p-1 mt-1 transition-colors hover:text-redis-red-500"> <span class="sr-only">Open main menu</span> <svg width="24" height="18" viewBox="0 0 24 18" fill="currentColor" xmlns="http://www.w3.org/2000/svg"> <rect width="24" height="1.5"/> <rect y="8.25" width="24" height="1.5" /> <rect y="16.5" width="24" height="1.5"/> </svg> </button> </div> </div> <nav data-menu class="hidden absolute left-0 top-[70px] h-[calc(100vh-70px)] w-full overflow-y-auto bg-white pb-12 xl:hidden"> <ul class="space-y-4 bg-white p-4"> <li data-products-mobile-menu-toggle aria-expanded="false" class="border-b border-b-redis-pen-300 py-4 last:border-none"> <div class="flex items-center justify-between"><span class="text-lg font-medium">Products</span> <button> <span data-products-mobile-menu-open-icon><svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12 6L-4.76837e-07 6" stroke="#FF4438" /> <path d="M6 12L6 -4.76837e-07" stroke="#FF4438" /> </svg></span> <span data-products-mobile-menu-close-icon class="hidden"><svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12 6L-4.76837e-07 6" stroke="#FF4438" /> </svg></span> </button> </div> <div data-products-mobile-menu class="hidden"> <ul class="space-y-4 py-4"> <li class="active:text-redis-red-500"> <a class="block w-full py-2" href="https://redis.io/cloud/"> Redis Cloud <p class="mt-2 text-xs font-normal text-gray-600">Fully managed and integrated with Google Cloud, Azure, and AWS.</p> </a> </li> <li class="active:text-redis-red-500"> <a class="block w-full py-2" href="https://redis.io/redis-for-ai/"> Redis for AI <p class="mt-2 text-xs font-normal text-gray-600">Build the fastest, most reliable GenAI apps with our advanced vector database.</p> </a> </li> <li class="active:text-redis-red-500"> <a class="block w-full py-2" href="https://redis.io/software/"> Redis Software <p class="mt-2 text-xs font-normal text-gray-600">Self-managed software with enterprise-grade compliance and reliability.</p> </a> </li> <li class="active:text-redis-red-500"> <a class="block w-full py-2" href="https://redis.io/data-integration/"> Redis Data Integration (RDI) <p class="mt-2 text-xs font-normal text-gray-600">Synchronize data in near-real time to make data fast—without writing code.</p> </a> </li> <li class="active:text-redis-red-500"> <a class="block w-full py-2" href="https://redis.io/docs/latest/get-started/"> Community Edition <p class="mt-2 text-xs font-normal text-gray-600">In-memory database for caching & streaming.</p> </a> </li> </ul> <div class="flex flex-col pt-4"> <div class="mb-4"> <h2 class="mb-6 pb-2 text-xs uppercase tracking-[2px] text-gray-400">Tools</h2> <ul class="space-y-4"> <li class="active:text-redis-red-500"><a class="block w-full py-2" href="https://redis.io/insight/">Redis Insight</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-2" href="https://redis.io/clients/">Clients and connectors</a></li> </ul> </div> <div class="pt-4"> <h2 class="mb-6 pb-2 text-xs uppercase tracking-[2px] text-gray-400">Get Redis</h2> <div class="flex text-center"><a class="w-full rounded border border-redis-pen-600 bg-redis-yellow-500 py-4 font-mono font-normal active:bg-redis-pen-800 active:text-white" href="https://redis.io/downloads/">Downloads</a></div> </div> </div> </div> </li> <li data-resources-mobile-menu-toggle aria-expanded="false" class="border-b border-b-redis-pen-300 py-4 last:border-none"> <div class="flex items-center justify-between"><span class="text-lg font-medium">Resources</span> <button> <span data-resources-mobile-menu-open-icon><svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12 6L-4.76837e-07 6" stroke="#FF4438" /> <path d="M6 12L6 -4.76837e-07" stroke="#FF4438" /> </svg></span> <span data-resources-mobile-menu-close-icon class="hidden"><svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12 6L-4.76837e-07 6" stroke="#FF4438" /> </svg></span> </button> </div> <div data-resources-mobile-menu class="hidden"> <ul class="py-4"> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/customers/">Customer Stories</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/partners/">Partners</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/support/">Support</a> </li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/community/">Community</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/events/">Events & Webinars</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/services/professional-services/">Professional Services</a></li> </ul> <div class="flex flex-col pt-4"> <div class="mb-4"> <h2 class="pb-2 text-xs uppercase tracking-[2px] text-gray-400">Learn</h2> <ul> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/docs/">Docs</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/commands/">Commands</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/docs/latest/get-started/">Quick starts</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/learn/">Tutorials</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://university.redis.io/">University</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/kb/">Knowledge Base</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/resources/">Resources</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/blog/">Blog</a></li> </ul> </div> </div> <div class="flex flex-col bg-redis-neutral-200 pt-4"> <div class="mb-4"> <h2 class="pb-2 text-xs uppercase tracking-[2px] text-gray-400">Latest</h2> <ul class="space-y-4"> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/release/">Releases</a></li> <li class="active:text-redis-red-500"><a class="block w-full py-4" href="https://redis.io/company/news/">News & Updates</a></li> </ul> </div> </div> <div class="flex flex-col bg-redis-neutral-200 pt-4"> <div class="mb-4"> <h2 class="mb-6 pb-2 text-xs uppercase tracking-[2px] text-gray-400">See how it works</h2> <div class="flex text-center"><a class="w-full rounded border border-redis-pen-600 bg-redis-yellow-500 py-4 font-mono font-normal active:bg-redis-pen-800 active:text-white" href="https://redis.io/demo-center/">Visit Demo Center</a></div> </div> </div> </div> </li> <li class="border-b border-b-redis-pen-300"> <div class="flex items-center justify-between"><a href="https://redis.io/docs/" class="block py-4 w-full text-lg font-medium">Docs</a></div> </li> <li> <div class="flex items-center justify-between"><a href="https://redis.io/pricing/" class="block py-4 w-full text-lg font-medium">Pricing</a></div> </li> </ul> <ul class="pt-6"> <li class="mx-auto flex w-11/12 text-center"><a class="my-2 w-full rounded-md border border-redis-pen-600 bg-redis-yellow-500 py-3 text-black active:bg-redis-pen-800 active:text-white" href="https://redis.io/try-free/">Try Redis</a></li> <li class="mx-auto flex w-11/12 text-center"><a class="my-2 w-full rounded-md border border-redis-pen-600 py-3 active:bg-redis-pen-800 active:text-white" href="https://redis.io/meeting/">Book a meeting</a></li> <li class="mx-auto flex w-11/12 text-center"> <a class="my-2 w-full py-3 active:text-redis-red-500" href="https://cloud.redis.io/"> Login <svg style="display:inline" width="12" height="11" viewBox="0 0 12 11" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12.0001 6.1931V4.6571L7.55212 0.209105L6.73612 1.0251L10.1441 4.4331L10.9441 4.8811L10.8641 5.0731L10.1441 4.8491L0 4.8491L-5.96046e-08 6.0011H10.1441L10.8641 5.7771L10.9441 5.9691L10.1441 6.4171L6.73612 9.8251L7.55212 10.6411L12.0001 6.1931Z" fill="#091A23" /> </svg> </a> </li> </ul> </nav> </header> <script> function openPage(page) { if (!page) { document.getElementById('headerLogo').classList.remove('hidden'); document.getElementById('headerBack').classList.add('hidden'); document.getElementById('headerMenu').classList.remove('hidden'); document.querySelectorAll('.menuPage').forEach(menuPage => menuPage.classList.add('hidden')); } else { document.getElementById('headerLogo').classList.add('hidden'); document.getElementById('headerBack').classList.remove('hidden'); document.getElementById('headerMenu').classList.add('hidden'); document.getElementById(page + 'Page').classList.remove('hidden'); } } </script> <main> <header class="relative h-48 bg-redis-ink-900 text-white overflow-hidden"> <div class="absolute w-1/2 h-full top-0 left-1/4"> <div class="absolute w-fit -top-10 md:-top-6 -right-80 md:-left-96 scale-75 md:scale-100"> <svg width="603" height="695" viewBox="0 0 603 695" fill="none" xmlns="http://www.w3.org/2000/svg"> <rect width="345.417" height="345.417" transform="matrix(0.866025 0.5 0 1 2 174.707)" fill="#FF4438" stroke="#091A23" stroke-width="4.0784" stroke-linejoin="bevel"/> <rect width="345.417" height="345.417" transform="matrix(0.866025 -0.5 0 1 301 347.412)" fill="#6B2B2B" stroke="#091A23" stroke-width="4.0784" stroke-linejoin="bevel"/> <rect width="345.417" height="345.417" transform="matrix(0.866025 0.5 -0.866025 0.5 301.158 2)" fill="#FF4438" stroke="#FF4438" stroke-width="4.0784" stroke-linejoin="bevel"/> <path fill-rule="evenodd" clip-rule="evenodd" d="M409.968 220.297L334.448 176.696L409.965 133.096L485.485 176.697L409.968 220.297Z" fill="white"/> <path fill-rule="evenodd" clip-rule="evenodd" d="M300.237 289.189L214.971 239.961L337.714 218.404L300.376 289.269L300.283 289.215L300.237 289.189Z" fill="white"/> <path fill-rule="evenodd" clip-rule="evenodd" d="M218.939 200.12C198.037 212.188 164.155 212.187 143.252 200.119C122.35 188.051 122.349 168.489 143.251 156.421C164.153 144.353 198.035 144.354 218.938 156.422C239.841 168.49 239.842 188.052 218.939 200.12Z" fill="white"/> <path d="M347.397 87.4418C349.062 95.9563 351.377 105.449 337.25 113.605C324.631 120.89 308.847 117.206 299.513 112.198C308.099 113.962 318.218 113.564 326.434 108.568C342.133 98.9013 338.663 84.0611 325.376 76.39C309.483 67.2144 286.118 67.4691 265.45 79.4017C250.669 87.936 237.956 101.743 234.78 113.805C243.766 119.145 260.724 123.044 261.252 121.235C264.215 110.899 267.681 103.347 273.292 97.3213C274.605 111.792 276.733 145.93 278.637 151.057C283.98 153.688 303.415 157.81 306.423 156.073C307.338 155.545 307.602 154.789 307.606 153.735C306.582 143.224 304.97 134.204 302.892 125.812C315.942 132.337 336.84 137.46 353.648 127.755C368.692 119.07 372.791 104.219 355.232 86.2284C353.019 84.0453 347.012 84.8063 347.394 87.4433L347.397 87.4418ZM310.59 85.9787C318.277 90.4164 314.465 96.9769 307.532 100.979C303.827 103.119 300.012 104.202 296.501 104.774C294.397 98.7773 292.092 92.7108 289.643 86.2087C298.722 82.4798 305.926 83.283 310.59 85.9758L310.59 85.9787Z" fill="white"/> <path d="M600.298 289.848L301.158 462.557L2.01843 289.848" stroke="#FF4438" stroke-opacity="0.15" stroke-width="2.71894" stroke-linejoin="bevel"/> <path d="M600.293 289.853L301.153 462.561L2.01367 289.853" stroke="#091A23" stroke-width="4.0784" stroke-linejoin="bevel"/> <rect width="345.417" height="345.417" transform="matrix(0.866025 0.5 -0.866025 0.5 301.158 2)" stroke="#091A23" stroke-width="4.0784" stroke-linejoin="bevel"/> <path d="M600.279 404.986L301.14 577.694L2 404.986" stroke="#091A23" stroke-width="4.0784" stroke-linejoin="bevel"/> </svg> </div> </div> <div class="relative max-w-[800px] mx-auto px-5 flex flex-col gap-8 md:items-center justify-center h-full z-10"> <h1 class="text-5xl font-medium">Docs</h1> <form class="flex flex-row items-center border border-white rounded-md px-6 gap-6 w-full md:w-4/5 bg-redis-ink-900" action="/chat"> <label class="" for="search-home" id="search-label-home"> <svg width="18" height="19" viewBox="0 0 18 19" stroke="currentColor" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M14.25 7.72059C14.25 11.591 11.2076 14.6912 7.5 14.6912C3.79242 14.6912 0.75 11.591 0.75 7.72059C0.75 3.8502 3.79242 0.75 7.5 0.75C11.2076 0.75 14.25 3.8502 14.25 7.72059Z" stroke-width="1.5"/> <path d="M12 12.3529L17 17.5" stroke-width="1.5"/> </svg> </label> <input id="seach-home" name="q" class="appearance-none bg-transparent text-base sm:text-lg text-white placeholder-white w-full h-16 focus:outline-none" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false" placeholder="Ask our AI-powered Redis copilot a question…" maxlength="64" type="text" value="" tabindex=""/> <input class="invisible" type="submit" class="hover:text-redis-pen-300" value=""/> </form> </div> </header> <div class="flex flex-col lg:flex-row gap-8 mx-auto px-4 md:px-11 py-6 md:py-28 max-w-[1920px]"> <div class="lg:sticky lg:top-32 w-full lg:w-64 h-fit lg:h-full shrink-0 text-sm font-mono font-normal"> <nav class="lg:hidden w-full lg:w-64 z-40 bg-white h-fit lg:h-full leading-7"> <div class="border border-opacity-50 border-redis-ink-900 rounded-md flex flex-col"> <button class="px-6 py-4 text-redis-ink-900 font-medium flex justify-between cursor-pointer lg:cursor-default" onclick="dropdownToggle()"> <div class="uppercase">Docs</div> <div id="dropdownChevron" class="lg:hidden self-center"><svg width="12" height="6" viewBox="0 0 12 6" fill="none" xmlns="http://www.w3.org/2000/svg"> <path fill-rule="evenodd" clip-rule="evenodd" d="M5.29289 6L0.646484 1.35359L1.35359 0.646484L6.00004 5.29293L10.6465 0.646484L11.3536 1.35359L6.70718 6H5.29289Z" fill="currentColor"/> </svg> </div> </button> <div id="dropdown" class="hidden lg:block border-t border-opacity-50 border-redis-ink-900 text-redis-pen-800"> <ul class="p-6"> <li><a class="py-2 hover:underline hover:text-redis-pen-600" href='/docs/latest/develop'>Develop with Redis</a></li> <li><a class="py-2 hover:underline hover:text-redis-pen-600" href='/docs/latest/integrate'>Libraries and tools</a></li> <li><a class="py-2 hover:underline hover:text-redis-pen-600" href='/docs/latest/operate'>Redis products</a></li> <li><a class="py-2 hover:underline hover:text-redis-pen-600" href='/docs/latest/commands'>Commands</a></li> <li><a class="py-2 hover:underline hover:text-redis-pen-600" href='/docs/latest/apis'>APIs</a></li> </ul> </div> </div> </nav> <nav class="hidden lg:block w-full lg:w-64 z-40 h-full leading-7"> <div class="flex flex-col gap-4"> <div class="flex flex-col border border-redis-ink-900 border-opacity-50 rounded-md"> <a class="px-6 py-4 rounded-t-md hover:bg-redis-pen-200" href='/docs/latest/develop'>Develop with Redis</a> <a class="px-6 py-4 hover:bg-redis-pen-200 border-y border-redis-ink-900 border-opacity-50" href='/docs/latest/integrate'>Libraries and tools</a> <a class="px-6 py-4 rounded-b-md hover:bg-redis-pen-200" href='/docs/latest/operate'>Redis products</a> </div> <div class="flex flex-col border border-redis-ink-900 border-opacity-50 rounded-md"> <a class="px-6 py-4 rounded-t-md hover:bg-redis-pen-200 text-redis-red-600" href='/docs/latest/commands'>Commands</a> <a class="px-6 py-4 rounded-b-md hover:bg-redis-pen-200 border-t border-redis-ink-900 border-opacity-50" href='/docs/latest/apis'>APIs</a> </div> </div> </nav> </div> <div class="lg:px-11 w-full flex flex-col gap-3"> <h2 class="text-5xl font-medium" id="operate">Get Started</h2> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Quickly set up a Redis cache, primary, vector, or custom database</h3> <p>Set up a Free Redis-managed database on AWS, GCP, or Azure</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./operate/rc/rc-quickstart/">Redis Cloud quick start</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./get-started/">Get started with Redis Community Edition →</a> </div> </div> </div> </div> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Build GenAI apps with Redis</h3> <p>Get started using Redis for retrieval augmented generation (RAG)</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./develop/get-started/rag/">Redis with RAG</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/ai/">Redis for AI docs and code examples →</a> </div> </div> </div> </div> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Optimize Redis for high-scale apps</h3> <p>Get the Redis Insight GUI on AWS EC2, Docker, Kubernetes, and desktop</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./operate/redisinsight/install/">Redis Insight install guide</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/tools/insight/#database-analysis">Performance and memory optimization user guide →</a> </div> </div> </div> </div> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Migrate data to or from Redis</h3> <p>Migrate data from files, data generators, relational databases, or snapshots</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./integrate/riot/">Redis input and output CLI tool</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./integrate/riot/quick-start/">Redis Input/Output Tool quick start →</a> </div> </div> </div> </div> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Connect with Redis client API libraries</h3> <p>Connect your application to a Redis database and try an example</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./develop/clients/">Redis client API library guides</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/clients/redis-py/">Python →</a> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/clients/dotnet/">C#/.NET →</a> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/clients/nodejs/">JavaScript →</a> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/clients/jedis/">Java →</a> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/clients/go/">Go →</a> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/clients/php/">PHP →</a> </div> </div> </div> </div> </div> <div class="lg:px-11 w-full flex flex-col gap-3"> <h2 class="text-5xl font-medium" id="operate">Deploy</h2> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Control your Redis deployments on-premises and on cloud platforms</h3> <p>Robust support for hybrid and multi-AZ environments</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./operate/rs/installing-upgrading/install/plan-deployment/">Redis deployment planning</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./operate/rs/databases/active-active/">Active-Active geo-distributed Redis →</a> </div> </div> </div> </div> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Deploy on Kubernetes</h3> <p>Get started with the Redis Software for Kubernetes container image</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./operate/kubernetes/deployment/quick-start/">Kubernetes deployment guide</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./operate/kubernetes/deployment/openshift/">Deploy Redis Software for Kubernetes with OpenShift →</a> </div> </div> </div> </div> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Ingest and sync data to Redis</h3> <p>Sync Redis Software with live data from your disk-based databases</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./integrate/redis-data-integration/quick-start-guide/">Pipeline quick start</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./integrate/redis-data-integration/">Redis Data Integration feature overview →</a> </div> </div> </div> </div> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Monitor Redis with Prometheus</h3> <p>Get started with the Redis Software integration for Prometheus and Grafana</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./integrate/prometheus-with-redis-enterprise/">Prometheus and Grafana with Redis</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./integrate/prometheus-with-redis-cloud/">Prometheus and Grafana with Redis Cloud →</a> </div> </div> </div> </div> <div class="w-full border-t border-t-redis-pen-300 mt-14 pt-14 flex flex-col md:flex-row gap-11 md:gap-0"> <div class="flex flex-col gap-5 flex-1"> <h3 class="text-2xl">Client tools to connect to a Redis server</h3> <p>You can use the CLI, Redis Insight, or the Redis VSCode extension to connect to Redis</p> <a class="w-fit p-4 text-sm font-mono bg-redis-yellow-500 text-redis-ink-900 border border-redis-pen-600 rounded hover:bg-redis-ink-900 hover:text-white transition-colors" href="./develop/tools/">Client tools overview guide</a> </div> <div class="flex-1 font-mono"> <div class="h-full flex flex-col md:flex-row gap-11 md:gap-8 md:pl-8 md:ml-8 md:border-l md:border-l-redis-pen-300"> <div class="flex flex-col gap-5 flex-1"> <p class="uppercase"></p> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/tools/cli/">Redis CLI →</a> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/tools/insight/">Redis Insight →</a> <a class="hover:text-redis-red-500 transition-colors text-balance" href="./develop/tools/redis-for-vscode/">Redis for VSCode →</a> </div> </div> </div> </div> </div> </div> </div> <script> function dropdownToggle() { document.getElementById('dropdownChevron').classList.toggle('rotate-180'); document.getElementById('dropdown').classList.toggle('hidden'); } </script> </main> <footer class="relative z-50 flex justify-center bg-white px-0 py-24 text-redis-pen-600 border border-t-redis-pen-300 text-[13px] font-sans"> <div class="flex w-full max-w-7xl flex-col gap-6 px-4 md:flex-row lg:px-8"> <div class="flex flex-col gap-8 md:max-w-[40%] md:flex-[40%]"> <a class="relative hover:text-redis-pen-400 w-[82px] mb-4" href="https://redis.io/"> <svg width="100%" height="100%" viewBox="0 0 85 27" fill="none" xmlns="http://www.w3.org/2000/svg"> <g clip-path="url(#clip0_8_219)"> <path fill-rule="evenodd" clip-rule="evenodd" d="M75.2909 13.8125C75.2909 10.8448 77.4892 9.12284 80.2371 9.12284C82.2888 9.12284 84.1207 10.1121 85 12.5668C84.7435 13.8125 83.2047 15.2047 82.5453 15.4246C81.9957 14.2522 81.3728 13.556 80.7866 13.556C80.0539 13.556 80.0172 14.069 80.0172 14.7284C80.0172 15.1955 80.151 15.8834 80.3119 16.7112C80.5549 17.9615 80.8599 19.5309 80.8599 21.1401C80.8599 24.0711 78.8082 26.2328 75.6573 26.2328C72.7721 26.2328 71.1778 24.3414 70.4665 21.3198C68.5818 24.6972 65.8257 26.2328 63.7134 26.2328C60.411 26.2328 59.6338 23.7919 59.7121 21.3161C58.3852 23.6612 55.831 26.2328 53.3815 26.2328C50.8809 26.2328 49.9976 24.0563 50.2002 21.5215C48.702 24.3122 45.9919 26.2328 43.3793 26.2328C40.5442 26.2328 39.141 23.9806 39.5951 21.189C37.6878 23.5333 34.1374 26.2328 30.4461 26.2328C26.2373 26.2328 24.4053 23.9632 24.1882 21.1193C22.1568 24.375 19.4187 26.3427 16.1573 26.3427C11.4493 26.3427 9.76537 22.1561 9.52032 18.7315C7.77547 21.0681 5.81377 23.4923 3.40733 26.1961C3.15086 26.4526 2.93103 26.5991 2.67457 26.5991C1.8319 26.5991 0.109914 22.8621 0 21.4698C0.723099 20.3478 5.28119 15.3398 8.95093 11.3079C10.2409 9.89066 11.4211 8.594 12.2863 7.6291C10.0389 8.30726 7.72169 9.65975 4.79957 11.7608C4.28664 12.1272 2.85776 8.7931 2.8944 6.22845C6.26509 3.73707 11.3944 2.16164 15.5345 2.16164C21.3233 2.16164 24.6573 5.38578 24.6573 9.8556C24.6573 13.5927 21.5431 17.6961 17 17.8427C14.6377 17.904 13.1237 16.578 12.3494 14.9405C12.4419 17.473 13.7587 20.5905 17.2931 20.5905C21.1462 20.5905 22.9965 18.2646 25.7559 14.7958C25.9352 14.5704 26.1183 14.3403 26.306 14.1056C28.6509 11.2112 31.3621 8.64655 35.319 8.64655C37.7371 8.64655 39.3858 10.1487 39.3858 12.4203C39.3858 15.1681 36.1616 18.9784 31.6552 18.9784C30.8855 18.9784 30.1839 18.877 29.5917 18.6766C29.5768 18.7921 29.5668 18.9058 29.5668 19.0151C29.5668 20.2974 30.0431 21.0668 32.1315 21.0668C35.2091 21.0668 38.1034 19.2349 41.6207 14.9483C45.0647 10.7349 47.6659 8.90302 50.4138 8.90302C52.2687 8.90302 53.6765 9.90832 54.2969 11.6014C57.9796 6.28253 61.1038 2.51388 63.75 0C66.3513 1.09914 68.2198 3.26078 67.7069 3.70043C65.7651 5.45905 59.2802 12.5302 56.7155 16.7435C56.056 17.8427 55.4332 19.0517 55.4332 19.6379C55.4332 20.1875 55.7629 20.3707 56.1293 20.3707C57.8898 20.3707 61.4176 16.2147 64.4645 12.6253C65.6026 11.2845 66.6736 10.0228 67.5603 9.08621C69.6121 9.92888 71.7004 11.7241 71.1875 12.347C68.4763 15.5711 66.4246 18.2091 66.4246 19.7112C66.4246 20.1142 66.5711 20.3707 67.1207 20.3707C68.1466 20.3707 69.0991 19.4547 70.6746 17.5129C71.0043 17.1099 71.4073 17.1099 71.6638 17.7328C72.3599 19.4181 73.3858 20.3341 74.1918 20.3341C75.1444 20.3341 75.6207 19.4914 75.6207 18.2091C75.6207 17.3327 75.5137 16.3138 75.4217 15.4365C75.3521 14.7733 75.2909 14.191 75.2909 13.8125ZM16.194 13.3362C18.1358 13.3362 20.2608 12.2737 20.2608 10.1121C20.2608 8.80024 19.4466 7.59084 17.2708 7.22257C17.156 7.40192 17.042 7.58017 16.9287 7.75739C15.8231 9.4858 14.7804 11.116 13.7281 12.7095C14.3586 13.0636 15.156 13.3362 16.194 13.3362ZM35.8319 13.9957C35.8319 13.4095 35.4655 13.0065 34.8793 13.0065C33.4094 13.0065 31.1923 15.0693 30.149 17.0613C30.5341 17.2101 30.9862 17.2931 31.472 17.2931C34.0733 17.2931 35.8319 15.3147 35.8319 13.9957ZM45.4677 19.3082C45.4677 19.9677 45.834 20.4073 46.6034 20.4073C48.9849 20.4073 51.9526 16.0841 51.9526 14.3254C51.9526 13.5927 51.5496 13.153 50.8901 13.153C48.7285 13.153 45.4677 17.2565 45.4677 19.3082ZM76.0599 6.08207C75.2172 7.47431 73.9349 9.04974 73.4586 9.52603C71.2603 8.61008 69.2086 6.77819 69.5017 6.26525C70.3077 4.83638 71.6267 3.29758 72.103 2.82129C74.3012 3.73724 76.353 5.60577 76.0599 6.08207Z" fill="currentColor"/> </g> <defs> <clipPath id="clip0_8_219"> <rect width="85" height="26.5991" fill="white"/> </clipPath> </defs> </svg> </a> <div class="flex flex-col justify-between mt-8 lg:mt-0 lg:mr-8 gap-8"> <div class="flex flex-row gap-5 order-first"> <a class="hover:text-redis-pen-400" href="https://www.facebook.com/Redisinc"> <svg width="11" height="20" viewBox="0 0 11 20" fill="none" xmlns="http://www.w3.org/2000/svg"> <g clip-path="url(#clip0_63_373)"> <path d="M11 0H8C6.67392 0 5.40215 0.526784 4.46447 1.46447C3.52678 2.40215 3 3.67392 3 5V8H0V12H3V20H7V12H10L11 8H7V5C7 4.73478 7.10536 4.48043 7.29289 4.29289C7.48043 4.10536 7.73478 4 8 4H11V0Z" fill="currentColor"/> </g> <defs> <clipPath id="clip0_63_373"> <rect width="11" height="20" fill="white"/> </clipPath> </defs> </svg> </a> <a class="hover:text-redis-pen-400" href="https://www.youtube.com/c/redisinc"> <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"> <path fill-rule="evenodd" clip-rule="evenodd" d="M19.7667 5.96696C19.4553 3.63427 18.2882 3.23898 15.9926 3.04099C14.0084 2.88274 11.7512 2.80396 10.0003 2.80396C8.24945 2.80396 5.95381 2.88274 4.00809 3.04099C1.71245 3.23898 0.506322 3.63427 0.194843 5.96696C0.0782076 7.03432 0 8.49764 0 10C0 11.5024 0.0775334 13.0048 0.194843 14.0331C0.506322 16.4055 1.71245 16.7611 4.00809 16.959C5.95381 17.157 8.24945 17.1961 10.0003 17.1961C11.7512 17.1961 14.0077 17.1564 15.9926 16.959C18.2882 16.7611 19.4553 16.4055 19.7667 14.0331C19.9225 13.0048 20 11.5024 20 10C20 8.49764 19.9225 7.035 19.7667 5.96696ZM7.97707 13.0836V6.95553L13.1913 10L7.97707 13.0842V13.0836Z" fill="currentColor"/> </svg> </a> <a class="hover:text-redis-pen-400" href="https://www.linkedin.com/company/redisinc/"> <svg width="17" height="20" viewBox="0 0 17 20" fill="none" xmlns="http://www.w3.org/2000/svg"> <path fill-rule="evenodd" clip-rule="evenodd" d="M0.893392 5.80254H4.03697V16.0894H0.893392V5.80254ZM2.44594 0.583496C3.49379 0.583496 4.34735 1.41532 4.34735 2.43651C4.34735 3.45769 3.49379 4.28952 2.44594 4.28952C1.39808 4.28952 0.583008 3.45769 0.583008 2.43651C0.583008 1.41532 1.39808 0.583496 2.44594 0.583496ZM5.89989 5.80254H9.00436V7.23993C9.66424 6.29437 10.7506 5.68941 11.9927 5.68941H12.8463C14.8253 5.68941 16.4163 7.27805 16.4163 9.16856V16.0894H13.3119V15.1438V10.5297C13.2728 9.35732 12.4583 8.44987 11.2553 8.44987C10.0522 8.44987 9.04347 9.35732 9.00436 10.5297V16.0894H5.89989V5.80254Z" fill="currentColor"/> </svg> </a> <a class="hover:text-redis-pen-400" href="https://www.instagram.com/redisinc/"> <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"> <path fill-rule="evenodd" clip-rule="evenodd" d="M5.39393 0H14.6061C17.5654 0 20 2.44044 20 5.40687V14.5931C20 17.5596 17.5654 20 14.6061 20H5.39393C2.43459 20 0 17.5596 0 14.5931V5.40687C0 2.44044 2.43459 0 5.39393 0ZM15.37 3.49319C15.9904 3.49319 16.5159 4.01918 16.5159 4.64186C16.5159 5.26377 15.9912 5.79053 15.37 5.79053C14.7017 5.79053 14.2241 5.26454 14.2241 4.64186C14.2241 4.01996 14.7017 3.49319 15.37 3.49319ZM9.97607 4.54595H10.0239C12.9832 4.54595 15.4657 7.03434 15.4657 10.0008C15.4657 13.0152 12.9832 15.4556 10.0239 15.4556H9.97607C7.01674 15.4556 4.58215 13.0152 4.58215 10.0008C4.58215 7.03434 7.01674 4.54595 9.97607 4.54595ZM9.97607 6.41166H10.0239C11.9809 6.41166 13.6037 8.03837 13.6037 10C13.6037 12.0096 11.9809 13.6363 10.0239 13.6363H9.97607C8.01913 13.6363 6.39633 12.0096 6.39633 10C6.39633 8.03837 8.01913 6.41166 9.97607 6.41166ZM5.44178 1.72262H14.559C16.6116 1.72262 18.2823 3.39728 18.2823 5.45483V14.5459C18.2823 16.6035 16.6116 18.2782 14.559 18.2782H5.44178C3.38915 18.2782 1.7185 16.6035 1.7185 14.5459V5.45483C1.7185 3.39728 3.38915 1.72262 5.44178 1.72262Z" fill="currentColor"/> </svg> </a> <a class="hover:text-redis-pen-400" href="https://twitter.com/Redisinc"> <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M11.9027 8.46864L19.3482 0H17.5838L11.119 7.3532L5.95547 0H0L7.8082 11.1193L0 20H1.76443L8.59152 12.2348L14.0445 20H20L11.9023 8.46864H11.9027ZM9.48608 11.2173L8.69495 10.1101L2.40018 1.29968H5.11025L10.1902 8.40994L10.9813 9.51718L17.5847 18.7594H14.8746L9.48608 11.2177V11.2173Z" fill="currentColor"/> </svg> </a> <a class="hover:text-redis-pen-400" href="https://github.com/redis/"> <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"> <path fill-rule="evenodd" clip-rule="evenodd" d="M9.9702 0C4.45694 0 0 4.35417 0 9.74086C0 14.0467 2.85571 17.6916 6.81735 18.9816C7.31265 19.0786 7.49408 18.772 7.49408 18.5141C7.49408 18.2883 7.47775 17.5142 7.47775 16.7077C4.70429 17.2884 4.12673 15.5466 4.12673 15.5466C3.68102 14.4176 3.02061 14.1275 3.02061 14.1275C2.11286 13.5308 3.08673 13.5308 3.08673 13.5308C4.09367 13.5953 4.62204 14.5306 4.62204 14.5306C5.51327 16.0142 6.94939 15.595 7.52714 15.337C7.60959 14.708 7.87388 14.2726 8.15449 14.0307C5.94245 13.8049 3.6151 12.9663 3.6151 9.2247C3.6151 8.1603 4.01102 7.28947 4.63837 6.6122C4.53939 6.37034 4.19265 5.37027 4.73755 4.03176C4.73755 4.03176 5.57939 3.77368 7.47755 5.03164C8.29022 4.81841 9.12832 4.70994 9.9702 4.70903C10.812 4.70903 11.6702 4.82204 12.4627 5.03164C14.361 3.77368 15.2029 4.03176 15.2029 4.03176C15.7478 5.37027 15.4008 6.37034 15.3018 6.6122C15.9457 7.28947 16.3253 8.1603 16.3253 9.2247C16.3253 12.9663 13.998 13.7887 11.7694 14.0307C12.1327 14.3371 12.4461 14.9176 12.4461 15.8369C12.4461 17.1431 12.4298 18.1915 12.4298 18.5139C12.4298 18.772 12.6114 19.0786 13.1065 18.9818C17.0682 17.6914 19.9239 14.0467 19.9239 9.74086C19.9402 4.35417 15.4669 0 9.9702 0Z" fill="currentColor"/> </svg> </a> </div> </div> <div class="hidden flex-col gap-4 md:flex"> <a class="hover:text-redis-pen-800" href="https://trust.redis.io/">Trust</a> <a class="hover:text-redis-pen-800" href="https://redis.io/legal/privacy-policy/">Privacy</a> <a class="hover:text-redis-pen-800" href="https://redis.io/legal/redis-website-terms-of-use/">Terms of use</a> <a class="hover:text-redis-pen-800" href="https://redis.io/legal/">Legal notices</a> </div> </div> <div class="flex flex-col gap-8 md:max-w-[15%] md:flex-[15%]"> <div> <h3 class="font-medium text-base uppercase text-redis-ink-900">Use Cases</h3> <div class="flex flex-col gap-4 pt-4"> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions/vector-database/">Vector database</a> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions/feature-stores/">Feature stores</a><a class="hover:text-redis-pen-800" href="https://redis.io/redis-for-ai/">Semantic cache</a> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions/caching/">Caching</a><a class="hover:text-redis-pen-800" href="https://redis.io/nosql/what-is-nosql/">NoSQL database</a> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions/leaderboards/">Leaderboards</a> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions/deduplication/">Data deduplication</a> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions/messaging/">Messaging</a> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions/authentication-token-storage/">Authentication token storage</a> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions/fast-data-ingest/">Fast-data ingest</a> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions/query-caching-with-redis-enterprise/">Query caching</a> <a class="hover:text-redis-pen-800" href="https://redis.io/solutions">All solutions</a> </div> </div> </div> <div class="flex flex-col gap-8 md:grid md:max-w-[45%] md:flex-[45%] md:grid-cols-3 md:justify-between"> <div> <h3 class="font-medium text-base uppercase text-redis-ink-900">Industries</h3> <div class="flex flex-col gap-4 pt-4"> <a class="hover:text-redis-pen-800" href="https://redis.io/industries/financial-services/">Financial Services</a> <a class="hover:text-redis-pen-800" href="https://redis.io/industries/gaming/">Gaming</a><a class="hover:text-redis-pen-800" href="https://redis.io/industries/healthcare/">Healthcare</a> <a class="hover:text-redis-pen-800" href="https://redis.io/industries/retail/">Retail</a> <a class="hover:text-redis-pen-800" href="https://redis.io/industries/">All industries</a> </div> </div> <div> <h3 class="font-medium text-base uppercase text-redis-ink-900">Compare</h3> <div class="flex flex-col gap-4 pt-4"> <a class="hover:text-redis-pen-800" href="https://redis.io/compare/elasticache/">Redis vs Elasticache</a> <a class="hover:text-redis-pen-800" href="https://redis.io/compare/memcached/">Redis vs Memcached</a> <a class="hover:text-redis-pen-800" href="https://redis.io/compare/memorystore/">Redis vs Memory Store</a> <a class="hover:text-redis-pen-800" href="https://redis.io/compare/community-edition/">Redis vs Source Available</a> </div> </div> <div> <h3 class="font-medium text-base uppercase text-redis-ink-900">Company</h3> <div class="flex flex-col gap-4 pt-4"> <a class="hover:text-redis-pen-800" href="https://redis.io/company/">Mission & values</a><a class="hover:text-redis-pen-800" href="https://redis.io/company/team/">Leadership</a> <a class="hover:text-redis-pen-800" href="https://redis.io/careers/">Careers</a><a class="hover:text-redis-pen-800" href="https://redis.io/company/news/">News</a> </div> </div> <div> <h3 class="font-medium text-base uppercase text-redis-ink-900">Connect</h3> <div class="flex flex-col gap-4 pt-4"> <a class="hover:text-redis-pen-800" href="https://redis.io/community/">Community</a><a class="hover:text-redis-pen-800" href="https://redis.io/events/">Events & webinars</a> <a class="hover:text-redis-pen-800" href="https://redis.io/company/news/">News</a> </div> </div> <div> <h3 class="font-medium text-base uppercase text-redis-ink-900">Partners</h3> <div class="flex flex-col gap-4 pt-4"> <a class="hover:text-redis-pen-800" href="https://redis.io/cloud-partners/aws/">Amazon Web Services</a> <a class="hover:text-redis-pen-800" href="https://redis.io/cloud-partners/google/">Google Cloud</a> <a class="hover:text-redis-pen-800" href="https://redis.io/cloud-partners/azure/">Microsoft Azure</a> <a class="hover:text-redis-pen-800" href="https://redis.io/partners/">All partners</a> </div> </div> <div> <h3 class="font-medium text-base uppercase text-redis-ink-900">Support</h3> <div class="flex flex-col gap-4 pt-4"> <a class="hover:text-redis-pen-800" href="https://redis.io/services/professional-services/">Professional services</a><a class="hover:text-redis-pen-800" href="https://redis.io/support/">Support</a> </div> </div> </div> <div class="absolute bottom-0 left-0 flex w-full flex-row gap-8 p-4 md:hidden"> <a href="https://trust.redis.io/">Trust</a> <a href="https://redis.io/legal/privacy-policy/">Privacy</a> <a href="https://redis.io/legal/redis-website-terms-of-use/">Terms of use</a> <a href="https://redis.io/legal/">Legal notices</a> </div> </div> </footer> <script> document.addEventListener('DOMContentLoaded', () => { const TableOfContents = { container: document.querySelector('#TableOfContents'), links: null, headings: null, intersectionOptions: { rootMargin: '0px', threshold: 1 }, previousSection: null, observer: null, init() { if (!this.container) return false this.handleObserver = this.handleObserver.bind(this) this.setUpObserver() this.findLinksAndHeadings() this.observeSections() }, handleObserver(entries, observer) { entries.forEach(entry => { let href = `#${entry.target.getAttribute('id')}` let link = this.links.find(l => l.getAttribute('href') === href) if (entry.isIntersecting && entry.intersectionRatio >= 1) { link.classList.add('visible') this.previousSection = entry.target.getAttribute('id') } else { link.classList.remove('visible') } this.highlightFirstActive() }) }, highlightFirstActive() { let firstVisibleLink = this.container.querySelector('.visible') this.links.forEach(link => { link.classList.remove('active') }) if (firstVisibleLink) { firstVisibleLink.classList.add('active') } if (!firstVisibleLink && this.previousSection) { this.container.querySelector( `a[href="#${this.previousSection}"]` ).classList.add('active') } }, observeSections() { this.headings.forEach(heading => { this.observer.observe(heading) }) }, setUpObserver() { this.observer = new IntersectionObserver( this.handleObserver, this.intersectionOptions ) }, findLinksAndHeadings() { this.links = [...this.container.querySelectorAll('a')] this.headings = this.links.map(link => { let id = link.getAttribute('href') return document.querySelector(id) }) } } TableOfContents.init() }) </script> <style> select { -webkit-appearance: none; -moz-appearance: none; appearance: none; background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"/></svg>'); background-repeat: no-repeat; background-position: right 1rem center; background-size: 1rem; } </style> <div class="sr-only w-screen h-screen fixed z-[200] top-0 left-0 cursor-auto flex flex-col bg-redis-ink-900/75 p-4 sm:p-6 md:p-[10vh] lg:p-[12vh]" id="search-container" role="button" aria-expanded="true" aria-haspopup="listbox" aria-labelledby="search-label" tabindex="0"> <div class="my-0 mx-auto w-full max-w-[47.375rem] flex flex-col min-h-0 rounded-lg shadow-lg bg-white p-6 gap-4"> <header class="flex flex-row gap-4 p-2"> <form id="search-form" class="grow flex flex-row gap-3 items-center" style="position: relative;"> <label class="search-magnifier-label" for="search-input" id="search-label" style="position: absolute; left:20px; pointer-events: none;"> <svg width="18" height="19" viewBox="0 0 18 19" stroke="currentColor" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M14.25 7.72059C14.25 11.591 11.2076 14.6912 7.5 14.6912C3.79242 14.6912 0.75 11.591 0.75 7.72059C0.75 3.8502 3.79242 0.75 7.5 0.75C11.2076 0.75 14.25 3.8502 14.25 7.72059Z" stroke-width="1.5"/> <path d="M12 12.3529L17 17.5" stroke-width="1.5"/> </svg> </label> <input id="search-input" style="height: calc(3rem - 2px);" class="w-full pl-12 border border-redis-pen-800 rounded-md search-input appearance-none focus:outline-none" aria-autocomplete="both" aria-labelledby="search-label" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false" placeholder="Search…" type="text" value=""> <button type="reset" title="Clear the query" class="search-reset" aria-label="Clear the query" hidden=""> <svg width="20" height="20" viewBox="0 0 20 20"> <path d="M10 10l5.09-5.09L10 10l5.09 5.09L10 10zm0 0L4.91 4.91 10 10l-5.09 5.09L10 10z" stroke="currentColor" fill="none" fill-rule="evenodd" stroke-linecap="round" stroke-linejoin="round" /> </svg> </button> <select id="search-select" style="height: calc(3rem - 2px);" class="w-2/5 pl-3 grow-0 border border-redis-pen-800 rounded-md search-filter bg-white text-left pr-8 appearance-none hidden md:block" autocomplete="off"> <option value="all" selected>All products</option> <option value="rs">Redis Enterprise</option> <option value="rc">Redis Cloud</option> <option value="oss_and_stack">Redis CE and Stack</option> <option value="redisinsight">Redis Insight</option> <option value="kubernetes">Redis Enterprise for K8s</option> <option value="redis-data-integration">Redis Data Integration</option> <option value="clients">Client Libraries</option> </select> </form> <button id="search-cancel" type="reset" aria-label="Cancel" class="px-3 border border-redis-pen-800 rounded-md text-center bg-redis-yellow-500 hover:bg-redis-yellow-300"> ESC </button> </header> <dl id="search-results" class="min-h-48 overflow-auto px-2" role="listbox"></dl> </div> </div> <script> const searchModal = (() => { const searchSite = encodeURIComponent(window.location.pathname) const searchButton = document.querySelector('#search-button') const searchContainer = document.querySelector('#search-container') const searchInput = searchContainer.querySelector('#search-input') const searchSelect = searchContainer.querySelector('#search-select') const resultsContainer = searchContainer.querySelector('#search-results') const style = document.createElement('style') let keys = {} let focusable let firstFocusable let lastFocusable function next (elem, selector) { let nextElem = elem.nextElementSibling if (!selector) return nextElem if (nextElem && nextElem.matches(selector)) return nextElem return null } function debounce(callback, delay) { let timeout return function() { clearTimeout(timeout) timeout = setTimeout(callback, delay) } } function searchSubmit(form) { if (form.id !== 'search-form') return false const searchTerm = searchInput.value.trim() const searchProduct = searchSelect.value if (searchTerm.length < 1) { resultsContainer.innerHTML = '' return } function search(url) { let promise = new Promise((resolve, reject) => { const req = new XMLHttpRequest() req.open('GET', url) req.onload = function() { if (req.status === 200) { resolve(JSON.parse(req.response)) } else { reject(Error(req.status)) } } req.send() }) return promise } function sortData(data) { const getCategories = (data) => data.reduce((a, c) => { if (!a.includes(c.hierarchy[0])) { a.push(c.hierarchy[0]) } return a }, []) const constructSectionTitle = (record) => { if (record.hierarchy && record.hierarchy.length > 2) { return record.hierarchy[1] } else { return record.title } } const mergeData = (data, categories) => categories.map((category) => { const obj = {} obj.category = category data.forEach((record) => { if (record.hierarchy[0] === category) { obj[record.title] = { path: constructSectionTitle(record), product: record.hierarchy[2], url: record.url, } } }) return obj }) return mergeData(data.results, getCategories(data.results)) } function escape_evil_chars(str_in) { return str_in.replaceAll('>','>').replaceAll('<', '<').replaceAll('&', '&').replaceAll('"','"').replaceAll("'",''') } function displayData(data) { resultsContainer.innerHTML = '' searchInput.focus() if (data.results.length < 1) { escapedSearchTerm = escape_evil_chars(searchTerm) resultsContainer.insertAdjacentHTML( 'beforeend', `<dt class="sr-only">${escapedSearchTerm}:</dt> <dd class="text-center"> No results for \"<span class="font-bold">${escapedSearchTerm}</span>\" </dd>` ) } else { sortData(data).forEach((result) => { resultsContainer.insertAdjacentHTML( 'beforeend', `<dt class="font-bold text-md my-4"> ${result.category} </dt>` ) delete result.category Object.keys(result).forEach((key, index) => { resultsContainer.insertAdjacentHTML( 'beforeend', `<dd class="search-item" role="option"> <a href="${result[key].url}"> <span class="search-item-icon"></span> <span class="search-item-content"> ${result[key].path && result[key].product ? `<div class="search-item-container"><span class="search-item-path">${result[key].path}</span><span class="px-2">→</span><span class="search-item-path">${result[key].product}</span></div>` : ''} <span class="search-item-title">${key.replace(new RegExp(`(^|)(${searchTerm})(|$)`, 'ig'), '$1<b class="search-term-match">$2</b>$3')}</span> </span> <span class="search-item-action"></span> </a> </dd>` ) }) if (!resultsContainer.querySelector('[aria-selected]')) resultsContainer.querySelector('.search-item').setAttribute('aria-selected', '') }) } return } function displayError(error) { console.log(error) } search(`\/convai\/api\/search-service?q=${searchTerm}*&p=${searchProduct}&site=${searchSite}`) .then(displayData) .catch(displayError) } function loadHandler(event) { style.innerHTML = ` [data-scroll-disabled="on"], [data-scroll-disabled="on"] body { touch-action: none; overscroll-behavior: none; -webkit-overflow-scrolling: auto; overflow: hidden; } [data-scroll-disabled="on"] .sticky { position: fixed; } ` document.head.appendChild(style) document.documentElement.dataset.searchState = 'off' } function getNextSibling(elem, selector, direction) { let sibling = direction === 'down' ? elem.nextElementSibling : elem.previousElementSibling while (sibling) { if (sibling.matches(selector)) return sibling sibling = direction === 'down' ? sibling.nextElementSibling : sibling.previousElementSibling } } function tabSelection(direction) { const currentSelection = resultsContainer.querySelector('[aria-selected]') if (!currentSelection || direction === 'down' && !currentSelection.nextElementSibling || direction === 'up' && !currentSelection.previousElementSibling) return false const nextSelection = getNextSibling(currentSelection, '.search-item', direction) if (!nextSelection) return false nextSelection.setAttribute('aria-selected', '') currentSelection.removeAttribute('aria-selected') resultsContainer.scrollTop = nextSelection.offsetTop - resultsContainer.offsetTop } function keyDownHandler(event) { switch (event.key) { case 'ArrowDown': if (document.documentElement.dataset.searchState === 'off' || !document.querySelector('.search-item')) return false event.preventDefault() tabSelection('down') break case 'ArrowUp': if (document.documentElement.dataset.searchState === 'off' || !document.querySelector('.search-item')) return false event.preventDefault() tabSelection('up') break case 'Tab': if (document.documentElement.dataset.searchState === 'off') return false if (focusable.length === 1) { event.preventDefault() break } if (event.shiftKey) { if (document.activeElement === firstFocusable) { event.preventDefault() lastFocusable.focus() } } else { if (document.activeElement === lastFocusable) { event.preventDefault() firstFocusable.focus() } } break case 'Escape': if (document.documentElement.dataset.searchState === 'off') return false stopSearch() break case 'Enter': if (!document.querySelector('.search-item:focus-within') && document.querySelector('.search-item[aria-selected]')) { event.preventDefault() document.querySelector('.search-item[aria-selected] a').click() } break case '/': if (document.documentElement.dataset.searchState === 'on') return false event.preventDefault() startSearch() break default: return false break } } function changeHandler(event) { searchSubmit(document.activeElement.closest('form')) } function keyUpHandler(event) { if (document.documentElement.dataset.searchState === 'off' || !document.activeElement.matches('.search-input')) return false switch (event.key) { case 'Meta': return false break case 'ArrowDown': return false break case 'ArrowUp': return false break case 'ArrowLeft': return false break case 'ArrowRight': return false break case 'Tab': return false break case 'Escape': return false break case 'Enter': return false break case '/': return false break default: searchSubmit(document.activeElement.closest('form')) break } } function multiKeyHandler(event) { if (document.documentElement.dataset.searchState === 'on') return false let { key, type } = event let isKeyDown = (type == 'keydown') keys[key] = isKeyDown if (isKeyDown && (keys.Control || keys.Meta) && keys.k) { event.preventDefault() startSearch() } } function clickHandler(event) { if (event.target.closest('#search-button')) { startSearch() } else if (event.target.closest('#search-cancel') || event.target.matches('#search-container')) { stopSearch() } } function startSearch() { sessionStorage.setItem('scroll-position', document.documentElement.scrollTop) document.documentElement.dataset.scrollDisabled = 'on' document.documentElement.dataset.searchState = 'on' allowFocus(searchContainer, true) trapFocus(searchContainer) searchInput.focus() } function stopSearch() { document.documentElement.dataset.searchState = 'off' document.documentElement.dataset.scrollDisabled = 'off' document.documentElement.scrollTop = sessionStorage.getItem('scroll-position') allowFocus(searchContainer, false) document.activeElement.blur() resultsContainer.innerHTML = '' searchInput.value = '' keys = {} } function submitHandler(event) { if (event.target.id === 'search-form') { event.preventDefault() return false } } function allowFocus(selector, state) { const focusable = selector.querySelectorAll('button, [href], input, select, textarea') focusable.forEach(el => el.setAttribute('tabindex', state ? '' : '-1')) selector.classList.toggle('sr-only') } function trapFocus(selector) { focusable = selector.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"]') firstFocusable = focusable[0] lastFocusable = focusable[focusable.length - 1] } document.addEventListener('DOMContentLoaded', loadHandler) document.addEventListener('click', clickHandler) document.addEventListener('keydown', event => debounce(keyDownHandler(event), 100)) document.addEventListener('keyup', event => debounce(keyUpHandler(event), 100)) searchSelect.addEventListener('change', event => debounce(changeHandler(event), 100)) document.addEventListener('keydown', multiKeyHandler) document.addEventListener('keyup', multiKeyHandler) document.addEventListener('submit', submitHandler) })() </script> </body> </html>