A feasibility study to observe the low-density Martian nightside ionosphere and the cislunar electron layer by radio occultation technique is presented. Since the total electron contents (TECs) along the ray paths of radio occultation in the ionospheres of Mars and the Moon are comparable to the fluctuation of the TEC of the terrestrial ionosphere, the distortions of radio occultation data by the terrestrial ionosphere should be taken into account. Local time and seasonal dependences of the terrestrial TEC fluctuations are investigated using the GPS receiver network, showing that the terrestrial ionosphere is calm at night in winter and that this period is suitable for the radio occultation measurements of the planetary ionospheres. A method is also developed to estimate the terrestrial TEC fluctuation along the ray path of radio occultation from GPS TEC data.