Atomic Blender (PDB/XYZ) - for Blender 2.8 and higher

Dear all.

For Blender 2.8, the two add-ons, Atomic Blender PDB and Atomic Blender XYZ, and the related Atomic Blender Utilities were put together into one single add-on called Atomic Blender (PDB/XYZ).
The documentation can be found here: Link. Note that the latter page still needs some improvements, which will be inserted relatively soon.

The two threads

Atomic Blender for loading PDB files into Blender 2.5


Atomic Blender for loading XYZ files into Blender

should not be considered anymore. Please, post any comments and questions in the thread here. Thank you. I try to supply some support in time.

Kind regards,



Apologies for the simple question: How do you make sure the utilities panel is active? It seems it should be when I am checking preferences > add-ons; nevertheless I am still unable to find it inside Blender. Any ideas?
Best wishes and thank you



First of all, I just want to let you know that I find the add-on extremely useful.

For this reason, I believe more people should know about it and I want to make it accesible to a wider audience that probably doesn’t even know what blender is.

I’m trying to help make a python package called sisl ( better. This package is very useful for geometry handling and analysis of atomic simulations. There is a class called Geometry that contains information of structures in a unified way. That is, many format readers and writers are implemented, but at the end everything is stored in the same way.

I would like to add a draw() method to this class that would allow users to generate the structure in blender by using your addon programatically. Is this possible?

My problem is that checking your code I have not found a function that, given a list of atoms and bonds in a certain format would draw the structure. Instead, I believe the drawing part is mixed with the import part. Am I right?

I would loooove to do this, so I’m really looking forward to your answer!



1 Like

Hi! Thank you for this amazing plug-in, I am a big fan!
I am very much interested in developing this further, however I couldn’t find the source code anywhere online. Is it available somewhere like github and if not would you be interested in making it available?

I am already using this in my molecular visualization Python package ( and I have made several journal covers using your plug-in. Thank you again!

1 Like

I’m trying the PDB importer, I’ve downloaded a couple of PDB and in the official preview I see a complex filament with twists but when I import it in Blender I get only spheres. Sorry I’m not a chemist.
How can I get the exact preview in Blender (without external software)?

Hi homeworker,

the PDB importer only shows the atoms in form of balls inside Blender. Other structures described in the PDB file are not shown. I hope that this is not too disappointing … :wink:

I haven’t been here for a while … sorry for being late:

ChemHGHenrik, thanks for your comments. Yes, you have to activate the panel in the Preferences. Then you have to go to the right side of the viewport (I think it’s called like this) and to 'activate this < small flash. There you see an entry Create where you then find the Atomic Blender panel. You find more details about the add-on here.
You are absolutely right, I should have described it in the preferences. I will do this by time … .

Pol_Febrer, thanks for your comments. Well, the loading and presentation of the atoms is rather quite complicated which is because of the Dupliverts technique in Blender that I’m using. This technique allows presenting several thousands of atoms without that the system hangs.
I’m not quite sure if I have correctly understood your objectives. To have some draw() like possibility, you could call the add-on as such in Python by using the main definition import_pdb. The condition is that you know the Blender settings (Ball type, sticks, etc.) and that the atom structure is described in a file. See line 1268 in the code. If you are still interested and if you have more questions then let me know …

kutaybsKBS, thx for your comments. You find the source code here.

Thanks for the reply, I’ve solved with a free java pdb viewer. Converted and imported in Blender.


First off, I’ve gotten a ton of use out of this add-on, and it’s a critical part of my visualization workflow. Up til now, I’ve been able to get everything I’ve wanted out of it. However, I’ve run into a problem recently which I think requires a bit more knowledge of how the system works.

I’m trying to render a crystal structure with ligand attached to the surface (rough sketch shown below). My vision for how this works would be to use the particle functionality in blender, and use weight paint to signify which atoms should have ligand attached, and what general direction the ligand should be pointed. Importing a .xyz as sphere meshes allows for particles to be added, but the weight paint function doesn’t work as I expect it to (only selects a single atom), and it’s not possible to join multiple particles into a single mesh (at least with the methods I’ve tried) even when I “make instances real”. So, my question is this:

Is this possible and simple? Or is this a fool’s errand, and I should just “pose” my ligands individually, and hope for a quasi-random look?


1 Like


Maybe because I’m super new to Blender, I can’t seem to get xyz file imported. I’m just getting error messages. What can I do to fix this? Thanks in advance!!

Dear newtoblender2020.

Please, can you attach the .xyz file, and can you send the Blender version and details about the operating system you are using? This would help me a lot, thanks.

Dear BesselFunct,

sorry for being late.

I have never played around with particles and the weight paint function. So, actually, I don’t know, sorry.

Keep in mind that the atomic ball structures are inside a dupliverts Blender structure: there is one representative ball, which is dublicated at all the vertices (all atomic positions of the atomic structure). May be you have to apply your operations to this ball. Otherwise, you can make ‘real’ objects from the dupliverts structure by selecting the structure and by typing Shift-Ctrl-A, see here. Attention, if you have many balls then it may happen that your Blender becomes slow. :wink:

I hope that helps and please tell me how it works at the end.


Hey @Blendphys,

Thanks for the reply. I have tried making ‘real’ objects from the dupliverts structure, but something strange happens when I try to weight paint them and add particles. I think it might be possible to get it to work, but it’s certainly not trivial. I think for now, I’m just going to pose things manually until I can figure out a way to make it automated.


Thank you for getting back to me. I can’t attach file because I’m a new user but I used mac with 2.82a and windows 2.90.1. File will open with Meshlab but it shows error message in Blender.

wtoblender2020, you can use this upload site here, it works with ASCII files.

EDIT: Do you mean Blender version 2.82a and 2.90.1?

Re BesselFunct

I know it is embarrassing :rofl: but I have no idea what particles might do with a molecular structure :crazy_face:. I have to read the manual about particles :face_with_monocle: in Blender since already a few people asked me to implement this … .

Cheers. :beer:

Yes, I was talking about the Blender version. This is the file I’m trying to import. Thanks again!

Hi newtoblender2020,

thanks for the file. I will have a look this weekend. BTW, each line has 6 entries, like:

6.257493 -2.138043 0.353669 176 165 159

I guess that the first three entries are x, y and z, right? What are the other three entries for? Are these the sticks?


This is a scanned image from Matterport scan. I’m not 100% sure with what the last 3 numbers are but looking online it may be red,green and blue. number is ranged from 0-255.

Hi newtoblender2020.

Sorry for being late, I’m quite busy at the moment … . I’m not using xyz anymore that often but now I remember again (I tried it out some minutes ago):

  • In the xyz file, you need a header, with the first line mentioning the total number of atoms. After this first line, there is a second line for any comments.

  • In line 3, the coordinates start.

  • In the first column of the coordinates, you have to mention the element in it’s short name version. For instance, for gold we have Au.

Here is an example of your .xyz file with the first ten entries:


Pt -14.672504 0.781957 2.048141
Pt -14.673726 0.781957 2.050637
Pt -14.672504 0.769228 2.050637
Pt -14.673115 0.781957 2.049389
Pt -14.673115 0.775593 2.050637
Pt -14.672504 0.775593 2.049389
Pt -14.672504 0.781957 2.055014
Pt -14.673115 0.781957 2.052825
Pt -14.672504 0.775593 2.052825
Pt -14.672504 0.761957 2.169580

As you can see, I have taken Pt as an element.

So, you have to change your xyz file first according to the conditions mentioned above. Then it should work. Note that you have 4113370 entries, this slows down your Blender, in particular the loading of the entire structure.

Let me know how it works …

EDIT: I just noticed that you can leave these three additional (color) numbers. They are just not considered during the import.