What Is SMILES and How Do You Use It to Search for Chemical Structures?
Updated
SMILES (Simplified Molecular Input Line Entry System) is a text notation that encodes a chemical structure as a single line of characters, so you can copy, paste, and search it in structure databases such as ChemSpider. Use it when you already have a machine-readable structure string and want to find the matching compound record, its names, synonyms, properties, and links. If you only have a common name or a drawn structure, a name search or structure editor is usually faster.
What SMILES actually encodes
A SMILES string describes atoms and the bonds between them using ASCII characters. It is a connectivity notation, not a picture and not a full chemical name.
- Atoms are written as element symbols:
Ccarbon,Ooxygen,Nnitrogen,Clchlorine. - Bonds are implied between adjacent atoms; ring closures use digits, and branches use parentheses.
- Aromatic atoms are often written in lowercase, e.g.
c1ccccc1for benzene. - Stereochemistry can be included with
@,@@,/, and\.
Example: ethanol is CCO. Each C is a carbon, the two carbons are bonded, and the final O is bonded to the second carbon.
How SMILES differs from names, synonyms, InChI, and InChIKey
These are all ways to identify a structure, but they behave differently in a search box.
| Identifier | What it is | Best for | Main limitation |
|---|---|---|---|
| Chemical name | Human-readable systematic or common name | Reading, publishing, everyday lookup | Many synonyms; spelling and naming variants |
| Synonym | Alternative trade or common name | Finding a compound when you know one alias | Not unique; one synonym can map to several records |
| SMILES | Line notation of atoms and bonds | Pasting a structure from software or a paper | Syntax-sensitive; can represent the same molecule in several valid ways |
| InChI | Standardized layered line notation | Canonical structure exchange | Long strings; less convenient to type |
| InChIKey | Fixed-length hash of InChI | Fast exact-match lookup | No structural detail visible in the string |
SMILES and InChI both encode structure, but SMILES is more compact and more common in cheminformatics toolkits, while InChI is designed as a standard. ChemSpider accepts SMILES alongside names, synonyms, InChI, and InChIKey as search inputs.
How to search ChemSpider with a SMILES string
- Get a valid SMILES string from your source — a paper's supporting information, a chemical drawing tool, or a database export.
- Open ChemSpider and locate the search field.
- Paste the SMILES string into the search box. ChemSpider recognizes SMILES input and runs a structure search rather than a text search.
- Submit the search and review the results list.
- Open the matching record to see the structure, names, synonyms, properties, vendor links, and references.
Expected result: if the string is valid and the structure exists in the database, you get a record page with the structure rendered and cross-references. If nothing matches, the string may be syntactically valid but the compound may not be indexed, or the string may contain an error.
Common pitfalls
- Invalid syntax. Unbalanced parentheses or ring-closure digits, or an element symbol in the wrong case (
cvsC), will fail or return the wrong structure. - Stereochemistry. A SMILES without
@or/markers describes connectivity but not stereochemistry, so it may match a different stereoisomer than you intended. - Tautomers and resonance forms. Different valid SMILES can describe the same molecule; a search may or may not normalize these depending on how the database handles them.
- Aromatic vs Kekulé forms.
c1ccccc1andC1=CC=CC=C1describe benzene differently; both are valid, but not every system treats them identically. - Salts and mixtures. A SMILES for a salt may include counterions, while the database record may be the free base or a specific form.
When to use SMILES versus a name or a drawing
- Use SMILES when you have a machine-generated string, need an exact connectivity match, or are copying from software output.
- Use a name or synonym when you only know what the compound is called and want the fastest lookup.
- Use a structure drawing when you want to build or edit the molecule visually and avoid syntax errors.
- Use an InChIKey when you need a fast, exact, fixed-length match and already have the key.
If your SMILES search returns nothing, try the compound's name or synonym, or draw the structure in the editor, before concluding the record is absent.