This uses \tiny but even that is not small enough so I use xurl package so that the string linebreaks to the margin width,


\documentclass{memoir} \usepackage{xurl} \makeindex \showindexmarks \makeatletter \renewcommand{\@showidx}[1]{% \insert\@indexbox{% \@sanitizeat \the\indexmarkstyle \hsize\marginparwidth \hangindent\marginparsep \parindent\z@ \everypar{}\let\par\@@par \parfillskip\@flushglue \lineskip\normallineskip \baselineskip .8\normalbaselineskip\sloppy \raggedright \leavevmode \vrule \@height .7\normalbaselineskip \@width \z@\relax \tiny\path{#1}\relax \vrule \@height \z@ \@depth .3\normalbaselineskip \@width \z@\relax }% \ifhmode\penalty\@M \hskip\z@skip\fi} \makeatother \begin{document} Here is a minimal working example\index{MinimalWorkingExample@Example!Working!Minimal}. Here is a minimal working example. Here is a minimal working example. \newpage Here is a minimal working example\index{MinimalWorkingExample@Example!Working!Minimal}. Here is a minimal working example. Here is a minimal working example. \printindex \end{document}
A version that works with non-ascii characters and just breaks lines at ! and @

\documentclass{memoir} \usepackage{xurl} \usepackage[T1]{fontenc} \makeindex \showindexmarks \makeatletter \renewcommand{\@showidx}[1]{% \insert\@indexbox{% \@sanitizeat \the\indexmarkstyle \hsize\marginparwidth \hangindent\marginparsep \parindent\z@ \everypar{}\let\par\@@par \parfillskip\@flushglue \lineskip\normallineskip \baselineskip .8\normalbaselineskip\sloppy \raggedright \leavevmode \vrule \@height .7\normalbaselineskip \@width \z@\relax \catcode`\@\active\lccode`\~`\@\lowercase{\def~}{\string @\penalty10\relax}% \catcode`\!\active\lccode`\~`\!\lowercase{\def~}{\string !\penalty10\relax}% \tiny\scantokens{#1}\relax \vrule \@height \z@ \@depth .3\normalbaselineskip \@width \z@\relax }% \ifhmode\penalty\@M \hskip\z@skip\fi} \makeatother \begin{document} Here is a minimal working example\index{MinimalWörkingExamplé@Example!Working!Minimal}. Here is a minimal working example. Here is a minimal working example. \newpage Here is a minimal working example\index{MinimalWörkingExamplé@Example!Working!Minimal}. Here is a minimal working example. Here is a minimal working example. \printindex \end{document}