611

I'm looking to cite a number of web pages using bibtex and I was wondering if there was a specific template of the form @<template name here> for doing that. If you could use the following website as an example that would be great

http://web.archive.org/web/20080207010024/http://www.808multimedia.com/winnt/kernel.htm

3
  • 2
    As an extra thing here - I just found that if you are want to attribute the site name as author (for example if I wanted to say that the author of this page was 'Stack Overflow' it's best to put 'Stack Overflow' as the `key' field, rather than the 'author' field. Because then latex formats as 'Stack Overflow' and not 'S. Overflow'. (might only apply with Harvard style)
    – Joe
    Oct 7, 2012 at 12:19
  • 2
    a nice resource covering, inter alia, natbib and biblatex (with screenshot-snippets of the PDF) is here: nschloe.blogspot.de/2009/06/bibtex-how-to-cite-website_21.html May 1, 2013 at 8:17
  • 1
    Re @Joe's comment: You can force BibTeX to treat the author name as something that cannot be abbreviated, by enclosing it in an extra pair of curly braces: author = {{Jemison Laboratory}},. Works for natbib, at least.
    – Mars
    May 18, 2016 at 16:50

8 Answers 8

723

A simple way of doing it in BibTeX is with a @misc entry:

@misc{WinNT,
  title = {{MS Windows NT} Kernel Description},
  howpublished = {\url{http://web.archive.org/web/20080207010024/http://www.808multimedia.com/winnt/kernel.htm}},
  note = {Accessed: 2010-09-30}
}

You should also perhaps include an author if you know it. And remember to load a package such as hyperref or url.


If you are using BibLaTeX there is an @online entry type:

@online{WinNT,
  author = {MultiMedia LLC},
  title = {{MS Windows NT} Kernel Description},
  year = 1999,
  url = {http://web.archive.org/web/20080207010024/http://www.808multimedia.com/winnt/kernel.htm},
  urldate = {2010-09-30}
}
13
  • 30
    +1 for the way to include the access date (very important!). There's an alternative way that uses howpublished to include the \url{} and [Acccessed: 30 September 2009], but that might not be style-independent. It's a little frustrating that BibTeX didn't officially keep up with web pages as an entry. Aug 27, 2012 at 15:35
  • 14
    There is a urldate field for biblatex, that acts as an accessed date field.
    – naught101
    Oct 15, 2012 at 2:22
  • 2
    Not sure if it's related to my specific configuration, but Biber kept complaining about the urldate field until I changed it to {2010-09-30}.
    – Pieter
    Mar 26, 2013 at 14:28
  • 5
    Thanks! For web sites that are dated, I prefer to use the month and year fields, but for sites that are undated, putting the date of access in the note field is a good way to go.
    – Nagel
    Oct 30, 2014 at 13:15
  • 3
    Great answer, @misc entry and howpublished with \url{} field seems the way to go. Check out the website bibtex.online to convert BibTeX to other formats such as APA, MLA or Chicago
    – David
    Oct 9, 2019 at 17:45
79

I always use the defaults suggested by Wikipedia (see "BibTeX entry" at the bottom), available if you click on "cite this page".

7
  • 7
    Neat trick. I had to change url to howpublished to make it work. How do I get that view for other wikipedia pages?
    – krupan
    Jan 8, 2013 at 19:08
  • 1
    @krupan I have no idea what you mean by "other wikipedia pages". What pages do you want to cite?
    – Habi
    Jan 10, 2013 at 12:07
  • 2
    @krupan in the left of every page you can found a link Cite this page, it complete the link that @habi provides with the current wikipedia page. Jan 22, 2015 at 19:55
  • @krupan Did Arturo answer your question? It might be of use to our other "TeXers"
    – Nathan
    Nov 2, 2019 at 4:58
  • 1
    I see it now, thank you. It's not there on mobile (even when I request the desktop site).
    – krupan
    Nov 5, 2019 at 20:37
22

The JabRef reference manager suggests to use the "electronic" type. So I do it like this:

@electronic{Rub1,
 author = {Rubino, Daniel},
 editor = {{Windows Phone Central}},
 title = {IE9 for Windows Phone 7: Adobe Flash, demos and development},
 url = {http://www.wpcentral.com/ie9-windows-phone-7-adobe-flash-demos-and-development-videos},
 urldate = {14.01.2013},
 originalyear = {18.02.2011}
}

In the BibTeX export of Citavi there is als the type "www". Depending on your editor you have to define the styles "electronic" and "www", so "misc" seems to be probably the safest.

But then you should use \bibliographystyle{alphadin} and do it like this:

@misc{Rub1,
 author = {Rubino, Daniel},
 editor = {{Windows Phone Central}},
 title = {IE9 for Windows Phone 7: Adobe Flash, demos and development},
 url = {http://www.wpcentral.com/ie9-windows-phone-7-adobe-flash-demos-and-development-videos},
 lastchecked = {14.01.2013},
 originalyear = {18.02.2011}
}
4
  • Nice! "@electronic" made the URL visible when using the CSL file at zotero.org/styles/ieee . Jun 18, 2018 at 11:16
  • if I use alphadin then there is no bib key in references. strange Jun 7, 2019 at 12:20
  • Should urldate be the current dat? or can I obtain its original created date from the url? @Benny Neugebauer
    – alper
    Oct 29, 2019 at 13:08
  • I'm lazy. Does JabRef have a tool that will automatically generate a citation when pointed at a StackExchange post like this one? Citing SE posts can be burdensome because of the often large number of contributors.
    – Shawn Eary
    Oct 22, 2021 at 15:56
10

I found a very good tutorial on http://www.polymtl.ca/biblio/utiliser/guide_bibtex.pdf (French; the link is now dead, available at the Wayback Machine)

With this, i have modified the ieeetr.bst file to integrate the ignored tags url and urldate to all the types of entries (style was imposed for the report at the end of study).

The file was renamed (mystyle) and placed in the same local folder as the ref.bib file. Called with

\bibliographystyle{mystyle}
\bibliography{ref}

(1) add the new entries :

ENTRY
  { address
...
    url
    urldate
  }
  {}
  { label }

(2) add this function

FUNCTION {format.url}
{ url empty$
    { "" }
    {   
        ". \emph{Disponible}~\url{" * url * "}" *
        urldate empty$
         { "there is url but no urldate in " cite$ * warning$ }
         { 
            "~(\emph{consult\'e le} " * urldate * ")" *
         }
         if$
    }
  if$
}

(3) for all types, call the function with format.url "" output ! Example for @incollection:

FUNCTION {incollection}
{ output.bibitem
  format.authors "author" output.check
  format.title "title" output.check
  blank.sep
  crossref missing$
    { format.in.ed.booktitle "booktitle" output.check
      format.bvolume output
      format.number.series output
      format.chapter.pages output
      format.addr.pub "publisher" output.check
      format.edition output
      format.date "year" output.check
    }
    { format.incoll.inproc.crossref output.nonnull
      format.chapter.pages output
    }      
  if$
  format.url "" output 
  new.block
  note output
  fin.entry
}

I hope it can help you

3
  • 1
    Hi madit, just added some code tags for ya :)
    – Scott H.
    Nov 6, 2012 at 22:19
  • Yes, even in sentences, it is better indeed. Thank you.
    – madit
    Nov 6, 2012 at 22:26
  • The link to the tutorial is dead
    – Hugal31
    Nov 24, 2017 at 17:25
8

Hm, it would seem that it isn't possible to cite webpages directly, but there does seem to be a workaround using the general purpose @misc field.

http://www.tex.ac.uk/cgi-bin/texfaq2html?label=citeURL

4

If you are creating your own bst file and you want it to incorporate web references, I use this function:

FUNCTION {internet}
{ output.bibitem
  format.titleclass output
  format.authors " " * "author" output.check
  title empty$
    {""}
    { title "t" change.case$ * ".\,\ " *}
  if$
  format.address output
  publisher empty$
    {
      institution empty$
        { }
        { institution "; " * output}
      if$
    }
    { publisher "; " * output}
  if$
  year empty$
    { " [date unknown; " }
    { year
      month empty$
        { " [\ignorespaces " * }
        { "~" * month * " [\ignorespaces " *}
      if$
    }
  if$
  revised empty$
    { "" * }
    { "revised~" * revised * "; " *}
    if$
  accessed empty$
    { "" * }
    { "accessed~"  * accessed * "]. " *}
    if$
  website *
  doi empty$
    {}
    { add.period$ " " * doi * }
  if$
  output
  add.period$
  format.referenceclass output
  fin.entry.noperiod
}

This with bib file entries like

@INTERNET{www11b,
    AUTHOR    = "Schultheis, J. D.",
    TITLE     = "Fun with Reference Citations",
    ADDRESS   = "Baltimore (MD)",
    PUBLISHER = "Random House",
    YEAR      = "2013", 
    MONTH     = sep # " 10",
    ACCESSED  = "2014 " # sep # " 26",
    WEBSITE   =
             "http://en.wikipedia.org/wiki/Trajectory\_of\_a\_projectile",
    DOI       = "\url{doi:10.10.1038/nphys1170}"     }

@INTERNET{www11a,
    TITLE    = "Flight Equations with Drag",
    WEBSITE  = "http://www.grc.nasa.gov/WWW/k-12/airplane/flteqs.html",
    ACCESSED = "2011 " # oct     }

@INTERNET{www11c,
    AUTHOR   = "Grissom, Gus",
    INSTITUTION = "Glenn Research Center, National Aeronautics
                   and Space Administration",
    TITLE    = "Flight Equations with Drag",
    ADDRESS  = "Cleveland (OH)",
    YEAR     = "1999",
    MONTH    = dec # "12",
    REVISED  = "2014 " # jun # " 12",
    ACCESSED = "2014 " # oct # " 7",
    WEBSITE  = "http://www.grc.nasa.gov/WWW/k-12/airplane/flteqs.html"}

@INTERNET{manktelow2010history,
    TITLE     = "History of taxonomy",
    AUTHOR    = "Manktelow, Mariette",
    WEBSITE   = "\url{http://www.atbi.eu/summerschool/files/%
                summerschool/Manktelow\_Syllabus.pdf}",
    ACCESSED  = "2014 Aug~26",
    ADDRESS   = "Uppsala (Sweden)",
    PUBLISHER = "Uppsala University Dept. of Systematic Biology",
    YEAR      = "2010"     }

@INTERNET{smith2014metcalf,
    TITLE    = "Assault on california power station raises alarm on
                potential for terrorism",
    AUTHOR   = "Rebecca Smith",
    WEBSITE  = "\url{http://online.wsj.com/news/articles/%
                SB10001424052702304851104579359141941621778}",
    ACCESSED = "2014 Aug 26",
    PUBLISHER= "The Wall Street Journal",
    MONTH    = feb,
    YEAR     = {2014}     }

I get this result:

enter image description here

0

Try this, please:

@misc{AdamsManual1,
  author = {MSC.\hspace{2pt}Software\hspace{2pt}Corporation},
  title = {{Adams Manual: Tire Models, using the Fiala handling force model}},
  howpublished = {\url{https://www.mscsoftware.com/product/adams; https://www.coursehero.com/file/13499609/tire-models/}},
  year = 2005,
  note = {Accessed: 2021-03-20}
}

The output:

Screenshot of the output of the above code.

-1

The most convenient way is to use cite maker website, take for example, bibme. It will be most preferred one also for you I guess.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy