Let $\pi:X \to S$ be a morphism of schemes (I can assume that $\pi$ is sufficiently nice, e.g. proper and flat, but certainly not smooth).



> 
> Does there exist a scheme $I\_{X/S}$ which parametrises the irreducible components of the fibres of $\pi$?
> 
> 
> 


In the case where $S = \mathrm{Spec}(k)$ for some field $k$ and $X$ is reduced, it is possible to construct such a scheme by hand. One takes $I\_{X/k}$ to be the product of the spectrum of the algebraic closure of $k$ in the function field of each irreducible component of $X$. This has the property that for any field extension $k \subset K$, the points $I\_{X/k}(K)$ are in bijection with those irreducible components of $X$ over $\bar{k}$ which are actually defined over $K$. 


I am looking for such a construction which works in greater generality. I'm naively hoping that this might be buried in EGA somewhere...


As a closely related example, note that it is quite easy to construct a scheme of connected components, at least when $X/S$ is proper. Namely, one simply takes the Stein factorisation of $\pi$ to obtain a finite scheme $S'/S$, whose fibres parametrise the connected components of the fibres of $\pi$ in a natural way.



Scheme of irreducible components
There is a definition of a functor of irreducible components in [that paper](https://perso.univ-rennes1.fr/matthieu.romagny/articles/composantes.pdf). If $\pi$ is finitely presented with geometrically reduced fibres, then the functor is representable by an étale algebraic space. As mentioned by Martin Bright, it is not separated in general; if it is, then it's a scheme (like all quasi-finite separated algebraic spaces).


