This article presents a multiport dc–dc converter (MPC) with four ports suitable for renewable energy applications. The converter is composed of two boost converters and a switched capacitor. The converter includes a bidirectional buck–boost converter to charge/discharge an energy storage. In the design procedure of the converter, existence of a common ground between the load and input ports, high voltage gain and continuous current of the ports are introduced, which make the converter appropriate for more applications. The converter boosts voltage with high gain in all of its operation modes. In addition, it operates in unbalanced conditions such as different powers and voltage levels of the input sources. According to the used switching strategy, controlling input power of the sources and output voltage is possible. Furthermore, the converter switches between charging and discharging modes automatically. To validate the feasibility and effectiveness of the proposed MPC, a prototype with 250 W nominal power is prepared. The converter boosts 20–400 V in all of the experimented modes.