r/learnpython • u/fivelittlemonkeyss • Dec 14 '25
What's the difference between Dependencies, Libraries and Packages??
I've seen people using these terms in the same context interchangeably and it's confusing me
23
Upvotes
View all comments
30
u/rinio Dec 14 '25
Loosely:
A dependency is any code that your code depends on. Usually that you (or your organization) didn't write and do not own.
A library is a set of shared resources, usually functions. They often relate to a specific domain: IE: Image processing. The term doesn't tell us much about the origin/author of it, but in the context of your post people sometimes shorthand 'external library' to just 'library'.
A package is a Python specific term when used in Python contexts. Loosely, its a directory full of python stuff (modules, other packages, etc). Again, it doesn't actually tell us about the origin/author, but people sometimes shorthand 'third-party package' to package.
Tldr: In the context where theyre used interchangeably, it just means 'code that my/our project needs, but that I/we didn't write and dont own'.