In linguistics, code-switching is when speakers alternate between two or more languages, dialects, or registers within a single interaction.