This document proposes a context-based indexing structure for search engines using ontology. It discusses how current search engines index documents based on terms, but not context. The proposed approach extracts contexts from documents using a context repository, thesaurus and ontology repository. Documents are then indexed based on these contexts rather than terms. An algorithm is presented where documents are first preprocessed and contexts extracted. Contexts are matched to an ontology to determine the specific document context. The index contains three fields - context, related terms, and document IDs. This allows searching the index based on context provided in the query, improving search quality by returning more relevant documents.