  Room temperature Ionic liquids (RTIL) received considerable attention as a
new class of materials with fundamental importance for energy storage
\cite{Armand2009, Uesugi2013} and active lubrication \cite{Palacio2010,
Dold2015, Smith2013a}. Their unique properties result from the competition of
strong electrostatic interactions with properly designed molecular structure to
avoid crystalization at room temperature. They are however unsual liquids,
which challenge fundamentally the classical frameworks of electrolytes. In
particular their behavior at electrified interfaces remains elusive with very
rich and exotic responses relevant to their electrochemical activity
\cite{Kornyshev2014,Merlet2012,Perkin2013,Atkin2009,Rotenberg2015,Endres2012,Bovio2009a,Bovio2009,Yokota2010}.
In this work, we use quartz tuning fork based AFM nanorheological measurements
to explore the properties of RTIL in nanometric confinement. We unveil a
dramatic change of the RTIL towards a solid-like phase below a threshold
thickness, pointing to a capillary freezing in confinement. This threshold
thickness is found to be intimately related to the metallic nature of the
confining materials, with more metallic surfaces facilitating capillary
freezing. This behavior is interpreted theoretically in terms of the shift of
the freezing transition, taking into account the influence of the electronic
screening on RTIL wetting of the confining surfaces, as described by the simple
Thomas-Fermi approach. Our findings provides fresh views on the properties of
confined RTIL with important implications for their statics and dynamics inside
nanoporous metallic structures. This also suggests applications to tune
nanoscale lubrication with the phase-changing RTIL, by varying the nature as
well as the patterning of the subtrate, and the application of active
polarisation.
