obabel(1) General Commands Manual (urm) obabel(1)

obabela converter for chemistry and molecular modeling data files

obabel [-H help-options]

obabel [OPTIONS] [-i input-type | -: "SMILES-string"] infile [-o output-type] -O outfile

obabel is a cross-platform program designed to interconvert between many file formats used in molecular modeling and computational chemistry and related areas.

Open Babel is also a complete programmers toolkit for developing chemistry software. For more information, se the Open Babel web pages <http://openbabel.org/>.

If only input and output files are given, Open Babel will guess the file type from the filename extension.

-: "SMILES-string"
Enter SMILES string and use it in place of an input file. The SMILES string should be enclosed in quotation marks. More than one can be used, and a molecule title can be included if enclosed in quotes.
options
Format-specific input options. See -H format-ID for options allowed by a particular format
Append text to the current molecule title
Append the molecular formula after the current molecule title
Convert dative bonds: e.g., [N+]([O-])=O to N(=O)=O
Center atomic coordinates at (0,0,0)
Combine molecules in first file with others having the same name
Continue after errors
Delete Hydrogens
2
Filter the level of errors and warnings displayed:
1 = critical errors only
2 = include warnings too (default)
3 = include informational messages too
4 = include "audit log" messages of changes to data
5 = include debugging messages too
#
For multiple entry input, start import with molecule # as the first entry
Output the available fingerprint types
Add hydrogens
Output usage information
format-ID
Output formatting information and options for format specified
Output formatting information and options for all formats
Specifies input format, see below for the available formats
 
Join all input molecules into a single output molecule entry
Translate computational chemistry modeling keywords (e.g., GAMESS and Gaussian)
Produce multiple output files, to allow:
  • Splitting one input file - put each molecule into consecutively numbered output files
  • Batch conversion - convert each of multiple input files into a specified output format
#
For multiple entry input, stop import with molecule # as the last entry
format-ID
Specifies output format, see below for the available formats
outfile
Specify the output file. This option applies to obabel only.
Add Hydrogens appropriate for pH (use transforms in phmodel.txt)
Add or replace a property (e.g., in an MDL SD file)
SMARTS
Convert only molecules matching the SMARTS pattern specified
Separate disconnected fragments into individual molecular records
All input files describe a single molecule
title
Add or replace molecular title
options
Format-specific output options. See -H format-ID for options allowed by a particular format
SMARTS
Convert only molecules NOT matching SMARTS pattern specified
Output version number and exit
Compress the output with gzip

The following formats are currently supported by Open Babel:

Individual file formats may have additional formatting options.

Input format options are preceded by 'a', e.g. -as

Output format options are preceded by 'x', e.g. -xn

For further specific information and options, use -H<format-type>
e.g., -Hcml

Standard conversion:

obabel ethanol.xyz -Oethanol.pdb
Conversion from a SMI file in STDIN to a Mol2 file written to STDOUT:
obabel -ismi -omol2
Split a multi-molecule file into new1.smi, new2.smi, etc.:
obabel infile.mol -Onew.smi -m

obenergy(1), obfit(1), obgrep(1), obminimize(1), obprop(1), obrotate(1), obrotamer(1). The web pages for Open Babel can be found at: <http://openbabel.org/>

A cast of many, including the currrent maintainers Geoff Hutchison, Chris Morley, Michael Banck, and innumerable others who have contributed fixes and additions. For more contributors to Open Babel, see <http://openbabel.org/wiki/THANKS>

Copyright (C) 1998-2001 by OpenEye Scientific Software, Inc.
Some portions Copyright (C) 2001-2007 by Geoffrey R. Hutchison

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation version 2 of the License.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

October 10, 2019 Open Babel 3.1