PDB to SDF
v1.0Convert ligand and peptide PDB coordinates to SDF with RDKit bond perception.
To convert PDB to SDF, isolate the ligand in its own PDB file, read it with RDKit, Open Babel, or PyMOL, and write it out as SDF. The program perceives bonds and bond orders from the coordinates and CONECT records, because PDB does not store them reliably. You can do it online with this converter, with the obabel command, or by saving a selection in PyMOL.
RDKit reads the coordinates and connectivity, writes an SDF, and reports the perceived SMILES and atom count, including for peptide ligands.
.pdb file and upload it.Infer bonds from proximity and Remove hydrogens on, or turn either off.Files.obabel ligand.pdb -O ligand.sdfOpen Babel takes both formats from the file extensions. Add -h to add hydrogens to a ligand taken from a crystal structure. Open Babel perceives bond orders with its own rules, so when its SDF and RDKit's disagree on a ligand, the PDB is ambiguous and the chemistry needs checking against a reference.
PyMOL can save a ligand straight out of a complex. Load the structure, then save only the ligand's residue name:
load complex.pdb
save ligand.sdf, resn ATPReplace ATP with the ligand's three-letter code from the HETATM lines.
Input .pdb:
COMPND ethanol
HETATM 1 C1 UNL 1 -0.953 0.048 0.042 1.00 0.00 C
HETATM 2 C2 UNL 1 0.488 -0.322 -0.189 1.00 0.00 C
HETATM 3 O1 UNL 1 1.277 0.325 0.738 1.00 0.00 O
HETATM 4 H1 UNL 1 -1.357 0.734 -0.733 1.00 0.00 H
HETATM 5 H2 UNL 1 -1.593 -0.863 0.022 1.00 0.00 H
HETATM 6 H3 UNL 1 -1.071 0.596 1.011 1.00 0.00 H
HETATM 7 H4 UNL 1 0.787 -0.141 -1.236 1.00 0.00 H
HETATM 8 H5 UNL 1 0.590 -1.426 -0.044 1.00 0.00 H
HETATM 9 H6 UNL 1 1.832 1.048 0.389 1.00 0.00 H
CONECT 1 2 4 5 6
CONECT 2 3 7 8
CONECT 3 9
ENDActual .sdf output:
ethanol
RDKit 3D
3 2 0 0 0 0 0 0 0 0999 V2000
-0.9530 0.0480 0.0420 C 0 0 0 0 0 0 0 0 0 0 0 0
0.4880 -0.3220 -0.1890 C 0 0 0 0 0 0 0 0 0 0 0 0
1.2770 0.3250 0.7380 O 0 0 0 0 0 0 0 0 0 0 0 0
1 2 1 0
2 3 1 0
M END
$$$$The blocks show the complete input and output for one ethanol molecule. Coordinates and chemistry shown here come from this conversion run.
| Input | Accepted format | Requirements |
|---|---|---|
| Molecules | .pdb upload | Ligand or peptide coordinates that RDKit can parse. Maximum file size: 50 MiB. |
| Setting | Default | What it does |
|---|---|---|
Infer bonds from proximity | On | Let RDKit infer additional bonds from atom distances. PDB does not reliably store bond orders, so inspect the resulting chemistry. |
Remove hydrogens | On | Remove explicit hydrogen atoms during PDB parsing. Turn off to retain the hydrogens present in the input. |
| Output | Contents |
|---|---|
| Results table | Name, Atoms, SMILES, Output file. |
molecule_1.sdf | Converted structure with perceived connectivity and coordinates. |
results.tsv | Tab-separated table with the same rows and values. |
report.json | Result rows, resolved settings and warnings. |
run.log | Tool, settings, result count and warnings; failures include their error. |
Downloads are available from Files. Inspect both the structure preview and the chemical content of the downloaded file.
PDB is primarily a coordinate format. CONECT records can provide connectivity; proximity bonding lets RDKit infer additional bonds from atom distances. Neither guarantees the intended bond orders, aromaticity or charges for an arbitrary ligand.
Prefer an original SDF or chemically complete SMILES when available. Successful conversion means a molecular file was written, not that perceived chemistry matches the intended ligand. Every result warns about this limitation. Compare the reported SMILES with a chemically complete reference.
By default, explicit hydrogens are removed during PDB reading. Turn Remove hydrogens off to retain input hydrogens. This does not add missing hydrogens, predict protonation or repair coordinates.
Supply the intended ligand or peptide as its own PDB. Amino-acid residue names do not prevent conversion. The converter reads the supplied structure without extracting a ligand; waters or unrelated molecules can otherwise enter the result.
For docking preparation from known chemistry, use SMILES to PDBQT. With a complete 3D SDF, SDF to PDBQT avoids interpreting chemistry from PDB.
Run obabel ligand.pdb -O ligand.sdf, adding -h if the ligand needs explicit hydrogens. Extract the ligand first, because Open Babel converts every atom in the file, including protein and water.
Yes. Load the PDB and run save ligand.sdf, resn ATP, replacing ATP with the ligand's residue name, or use File, then Export Molecule, and choose SDF. Saving a selection extracts the ligand and converts it in one step.
RDKit decides whether the supplied PDB can be parsed as a molecule. This converter does not extract ligands, repair a protein or prepare it for docking. For a ligand result, upload the isolated ligand or peptide rather than a protein complex.
It writes RDKit's perceived chemistry. Missing bond-order or charge information cannot be guaranteed without a complete chemical reference.
With Remove hydrogens on, explicit hydrogens are removed during reading. Heavy atoms remain in the parsed structure.
Generate SMILES strings from InChI identifiers for search, filtering, and modeling workflows.
Extract canonical SMILES strings from MDL MOL ligand files for cheminformatics workflows.
Extract canonical SMILES strings from MOL2 ligand files for cheminformatics workflows.
Export ligand poses from Meeko-prepared PDBQT to SDF while recovering chemical connectivity.
Convert SDF ligands to PDBQT with Meeko, preserving supplied coordinates.
Extract canonical SMILES strings from SDF ligand files, one record at a time or in batch.
Generate InChI identifiers from SMILES strings for registration and interoperability workflows.
Generate MOL2 files from SMILES strings for docking, scoring, and modeling workflows.
Generate 3D PDB files from SMILES strings for visualization and small-molecule workflows.
Generate 3D ligand coordinates from SMILES and prepare PDBQT files with Meeko.