# Property (@property)

say it: **“PROP-er-tee”** **/ˈprɑpərti/**

Lets a method be used like an attribute, with no brackets.

## What does `@property` do?

`@property` lets you use a method like an attribute, with no brackets. It's used for values worked out on the fly, or to check a value before it's saved.

```python
class Cart:
    def __init__(self, prices):
        self.prices = prices

    @property
    def total(self):
        return sum(self.prices)

cart = Cart([5, 10])
print(cart.total)  # 15, no brackets
```

Level: Freelancer · [More Python terms at this level](https://www.ask-codey.com/glossary?category=python&level=4)

Updated: November 17, 2026

Source: https://www.ask-codey.com/glossary/property-property
