Found answer here: http://stackoverflow.com/questions/1296358/subtract-days-from-a-date-in-javascripthttps://stackoverflow.com/questions/1296358/subtract-days-from-a-date-in-javascript
db.system.profile.find({
"timestamp" : {
$lt: new Date(),
$gte: new Date(new Date().setDate(new Date().getDate()-1))
}
})