ABSTRACT In this paper, we design and simulate a two-dimensional photonic crystal-based high speed logical encoder for optical computing application. The encoder consists of a ring resonator, four waveguides and two reflectors arranged in a hexagonal lattice platform. The optical encoder works on the interference effect which guides the propagation of light in the desired path. The light behavior is simulated with four different logic states. The Plane Wave Expansion (PWE) method is used to analyze the band gap and Finite Difference Time Domain (FDTD) analyzes the performance characteristics of the encoder, such as bit rate, delay time, and contrast ratio. The proposed structure has a footprint area of 143.84 µm2. The small compact size structure with simple defect paths reduces the encoder delay time, which in turn increase the data bit rate. The response time of the proposed encoder is 0.119 ps and bit rate is 8.403 Tbps. The encoder is designed with very low output power in “0” logic state and high output power in “1” logic state leading to high contrast ratio of 22.57 dB. Therefore, highly efficient 4 × 2 optical encoder is suitable to build in optical integrated circuits.