A symbol table is a data structure used by compilers and interpreters to store and retrieve the association between identifiers and their corresponding attributes, such as type, scope, and memory location. It plays a crucial role in semantic analysis, enabling efficient access and management of variables, functions, and other entities within a program.