8. Color the eight vertices of a cube with three colors, where at least one color is used to color exactly four vertices. Then the probability that the two endpoints of any edge are of different colors is $\qquad$

Translate the above text into English, please retain the original text's line breaks and format, and output the translation result directly.
8. $\frac{1}{35}$.

When one color is used to paint four vertices, the remaining two colors can be used to paint the remaining four vertices in any way. Therefore, the number of coloring methods is
$$
\mathrm{C}_{3}^{1} \mathrm{C}_{8}^{4}\left(\mathrm{C}_{4}^{0}+\mathrm{C}_{4}^{1}+\mathrm{C}_{4}^{2}+\mathrm{C}_{4}^{3}\right)=3 \times 70 \times 15 \text { (ways). }
$$

If it is required that the two endpoints of any edge are of different colors, then there are only two ways to color four vertices with one color. At this time, the remaining two colors can still be used to paint the remaining four vertices in any way. Thus, the number of such coloring methods is
$$
\mathrm{C}_{3}^{1} \cdot 2\left(\mathrm{C}_{4}^{0}+\mathrm{C}_{4}^{1}+\mathrm{C}_{4}^{2}+\mathrm{C}_{4}^{3}\right)=6 \times 15 \text { (ways). }
$$

Therefore, the required probability is $\frac{6 \times 15}{3 \times 70 \times 15}=\frac{1}{35}$.