Indexes are used to find rows with specific column values quickly. Without an index, MySQL must begin with the first row and then read through the entire table to find the relevant row. The larger the table, the more this costs. If the table has an index for the columns, MySQL can quickly determine the position to seek to in the middle of the data file without having to look at all the data.

Most MySQL indexes (PRIMARY KEY, UNIQUE, INDEX, and FULLTEXT) are stored in B-Trees.

MySQL uses indexes for these operations: