Code
\documentclass{article} \usepackage{etoolbox} \makeatletter \newcounter{introsection} \newcommand*{\introsectionmark}[1]{} \renewcommand \theintrosection {\@arabic\c@section} \newcommand\introsection{% \@start@introsection {section}{1}{\z@}% {-3.5ex \@plus -1ex \@minus -.2ex}% {2.3ex \@plus.2ex}% {\normalfont\Large\bfseries} } \let\@start@introsection\@startsection \patchcmd{\@start@introsection}{\@sect}{\@introsect}{}{} \def\intronumberline#1{\hspace*{-3.5pt}\numberline{\fbox{#1}}\hspace*{2.5pt}} \def\addintrocontentsline#1#2#3{% \addtocontents{#1}{\protect\contentsline{#2}{\hspace*{-3.5pt}\fbox{#3}}{\thepage}}} \let\@introsect\@sect \patchcmd{\@introsect}{\addcontentsline}{\addintrocontentsline}{}{} %\patchcmd{\@introsect}{\numberline}{\intronumberline}{}{} \def\intromatter{\let\section\introsection} \def\mainmatter{\let\section\ltx@section} \let\ltx@section\section \makeatother \begin{document} \tableofcontents \introsection{One} \introsection{Two} \section{Three} \section{Four} \end{document}
Remark
This solution provides a sectioning command \introsection that can be used as usual, but adds a framebox around its toc entry. Alternatively you can have the box only around the section number by using line 21 instead of 20.
If you are using the article class you can also use the above defined macros \intromatter and \mainmatter which are meant to be used like the similar and anologous ones of the book class:
\begin{document} \tableofcontents \intromatter \section{One} \section{Two} \mainmatter \section{Three} \section{Four} \end{document}
Output

Addendum
You can of course use another styling of frame by replacing \fbox with another macro that fulfills your needs.