A novel and accurate refractive index profile synthesis method for planar optical waveguides is presented and demonstrated using the transmitted near-electric-field-data. This method is based on the inverse transmission-line (TL) technique. From Maxwell's equations, a TL equivalent circuit (electric T-circuit) for the refractive index profile of a planar optical waveguide is derived. The authors demonstrate how to use this model to carry out the inverse problem and synthesise the exact refractive index profile numerically from near-field-data. The TL method can reconstruct arbitrary refractive index profiles for planar optical waveguides that support singlemode or multimodes. The cases of both symmetric and asymmetric arbitrary refractive index profile planar waveguides are discussed. The accuracy of the reconstructed waveguides is examined numerically.