<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/effectively-use-history-commands-in-linux-2jzjccszo" -->

---
title: Effectively Use History Commands in Linux | daily.dev
description: The history command in Linux is a powerful tool that allows users to view, search, and manage their command history. By pressing the up key or using the...
canonical: https://daily.dev/posts/effectively-use-history-commands-in-linux-2jzjccszo
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Effectively Use History Commands in Linux | daily.dev
og:description: The history command in Linux is a powerful tool that allows users to view, search, and manage their command history. By pressing the up key or using the...
og:url: https://daily.dev/posts/effectively-use-history-commands-in-linux-2jzjccszo
og:image: https://api.daily.dev/og/posts/2jZjCCSzo.png
og:image:alt: Effectively Use History Commands in Linux
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Effectively Use History Commands in Linux

**[It's Foss](https://daily.dev/sources/itsfoss)** · 6 min read · 45 upvotes · 1 comments

## Summary

The history command in Linux is a powerful tool that allows users to view, search, and manage their command history. By pressing the up key or using the history command, users can see previously run commands. Commands can be rerun using their corresponding numbers, and the command history can be searched using grep or reverse search. Additionally, specific commands can be excluded from history, and there are methods to manage command history across multiple terminal sessions. The tutorial also covers advanced tips like replacing text in the last run command and manually clearing or deleting history entries.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://itsfoss.com/history-command/>

## Community discussion

Top comments from developers on daily.dev.

**@shashoto** · 1 upvotes

> Another tool I use for command history is Atuin. It makes searching for commands and browsing through it way easier.

---

Tags: [#bash](https://daily.dev/tags/bash), [#linux](https://daily.dev/tags/linux)

[View this post on daily.dev](https://daily.dev/posts/effectively-use-history-commands-in-linux-2jzjccszo)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Effectively Use History Commands in Linux","url":"https://daily.dev/posts/effectively-use-history-commands-in-linux-2jzjccszo","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/effectively-use-history-commands-in-linux-2jzjccszo"},"datePublished":"2024-07-23T13:09:55.504Z","dateModified":"2024-08-30T02:19:47.637Z","description":"The history command in Linux is a powerful tool that allows users to view, search, and manage their command history. By pressing the up key or using the...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/07ee89c1a681b41b813ed3307f143332?_a=AQAEuiZ","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/07ee89c1a681b41b813ed3307f143332?_a=AQAEuiZ","isAccessibleForFree":true,"articleSection":"It's Foss","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"It's Foss","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/582e3faed71842bfb9d3840a787d6700","url":"https://daily.dev/sources/itsfoss"},"commentCount":1,"discussionUrl":"https://daily.dev/posts/effectively-use-history-commands-in-linux-2jzjccszo","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":45},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":1}],"keywords":"bash,linux","timeRequired":"PT6M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"It's Foss","item":"https://daily.dev/sources/itsfoss"},{"@type":"ListItem","position":3,"name":"Effectively Use History Commands in Linux"}]}
{"@context":"https://schema.org","@type":"WebPage","@id":"https://daily.dev/posts/effectively-use-history-commands-in-linux-2jzjccszo","comment":[{"@type":"Comment","text":"Another tool I use for command history is Atuin. It makes searching for commands and browsing through it way easier.","datePublished":"2024-07-30T09:11:52.965Z","url":"https://daily.dev/posts/2jZjCCSzo#c-zH0fONZbL","author":{"@type":"Person","name":"Shashoto Nur","url":"https://daily.dev/shashoto","image":"https://lh3.googleusercontent.com/a-/AOh14GhR7VHq5WE-qNeuftEgUuRxYQBHL_zQ2mOiRpbOfg=s100"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1}}]}
```

