# How to add the author name?

**URL:** https://talk.jekyllrb.com/t/how-to-add-the-author-name/951
**Category:** Help
**Created:** [September 3, 2017, 5:28pm UTC](https://talk.jekyllrb.com/t/how-to-add-the-author-name/951 "2017-09-03T17:28:36Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![yashumittal](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/yashumittal/32/1260_2.png) [@yashumittal](https://talk.jekyllrb.com/u/yashumittal)
#### Post date: [September 3, 2017, 5:28pm UTC](https://talk.jekyllrb.com/t/how-to-add-the-author-name/951/1 "2017-09-03T17:28:36Z")

</div>

I also want to add the author name to the posts.

What should I do for that?

---

<div class="post-metadata">

### Author: ![rdyar](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/rdyar/32/710_2.png) [@rdyar](https://talk.jekyllrb.com/u/rdyar)
#### Post date: [September 3, 2017, 11:23pm UTC](https://talk.jekyllrb.com/t/how-to-add-the-author-name/951/2 "2017-09-03T23:23:07Z")

</div>

should be pretty easy, just add front matter to the post - `author: Bob Smith` and then in the layout you can do `{{page.author}}` you could also test to see if it exists by doing an if:

`{% if page.author %}Written by: {{page.author}}{% endif %}`

---

<div class="post-metadata">

### Author: ![yashumittal](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/yashumittal/32/1260_2.png) [@yashumittal](https://talk.jekyllrb.com/u/yashumittal)
#### Post date: [September 4, 2017, 10:06am UTC](https://talk.jekyllrb.com/t/how-to-add-the-author-name/951/3 "2017-09-04T10:06:41Z")

</div>

Will this code work?

```auto
{% if page.author %}
  {% include author/{{page.author}}.html %}
{% endif %}

```

If we have lots of authors and we want to include a file specific to the author name.

AND

If we add the `author: -name-`, then will it also show up in the RSS feed?

---

<div class="post-metadata">

### Author: ![DavidDarnes](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/daviddarnes/32/1349_2.png) [@DavidDarnes](https://talk.jekyllrb.com/u/DavidDarnes)
#### Post date: [September 5, 2017, 8:53am UTC](https://talk.jekyllrb.com/t/how-to-add-the-author-name/951/4 "2017-09-05T08:53:38Z")

</div>

That should work. You could also do the following:

```auto
---
author: 'Author Name'
---

{% include author-bio.html name: page.author %}

```

Then you could deal with the logic inside the partial
