Anti‐seizures have been frequently used for a long time. Most of these antiepileptic drugs, which are used on a daily basis, are central nervous system depressants, and their excessive use damages the respiratory system. Therefore, in order to achieve the desired therapeutic goals, avoiding side effects and drug interactions, it is very important to use targeted medications. Among the metal–organic frameworks (MOFs), ZIF nanoparticles have several advantages such as smooth capillary flow and the slow release of drugs, circulating and preventing increased drug concentrations in plasma. Gabapentin, levetiracetam, phenytoin, and valproate are effective drugs in the treatment of epilepsy. In this investigation, the zeolitic imidazolate frameworks ZIF‐67, ZIF‐90, and ZIF‐8 are used as carriers for the above drugs, and their loading processes are evaluated. Among these MOFs, the highest loading values are attained in the case of ZIF‐8. Therefore, the latter MOF is synthesized via a new simple method and characterized by X‐ray diffraction (XRD), Fourier transform infrared (FT‐IR), scanning electron microscopy (SEM), and X‐ray photoelectron spectroscopy (XPS) techniques. Also, the release of these drugs was measured from the pores of ZIF‐8, and the slow release of these drugs indicated that the framework could be used as a suitable carrier for a wide range of antiepileptic drugs. Finally, the in vitro cytotoxicity of gabapentin‐ZIF‐8 against Hep‐G2 liver cancer cells was investigated by MTT assay. This study confirmed a significant decrease in the MTT signal compared with the untreated cells, so the drug‐loaded ZIF‐8 could reduce the metabolic activity of cancer cells. Therefore, this nanoparticle can be used as a carrier for the delivery of the studied drugs.