from django.utils import timezone

class Product(models.Model):
    name = models.CharField(max_length=225)
    created_on = models.DateTimeField(auto_now_add=True)
    def is_new(self):
        now =
        diff = now - self.created_on
        if diff.days < 7: # 7 is the number of days
            return True
            return False  

// in your template
<h4>{{ }}{% if product.is_new %}<span>სიახლე</span>{% endif %}</h4>
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter